/**
 * ZOZO Tracking Dashboard Styles
 * Main stylesheet for tracking dashboard interface
 */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
    background: #f5f5f5;
    padding: 20px;
    color: #333;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
}

h1 {
    color: #1f2937;
    margin-bottom: 24px;
    font-size: 2em;
}

/* Stats Cards */
.stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    padding: 24px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.stat-card h3 {
    font-size: 0.875rem;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 8px;
}

.stat-card .value {
    font-size: 2.5rem;
    font-weight: 700;
    color: #1f2937;
}

/* Card Component */
.card {
    background: white;
    padding: 24px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    margin-bottom: 24px;
}

.card h2 {
    font-size: 1.25rem;
    color: #1f2937;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 2px solid #e5e7eb;
}

/* Tables */
table {
    width: 100%;
    border-collapse: collapse;
}

th,
td {
    text-align: left;
    padding: 12px;
    border-bottom: 1px solid #e5e7eb;
}

th {
    background: #f9fafb;
    font-weight: 600;
    color: #374151;
    font-size: 0.875rem;
}

tr:hover {
    background: #f9fafb;
}

/* Progress Bar */
.progress-bar {
    height: 8px;
    background: #e5e7eb;
    border-radius: 4px;
    overflow: hidden;
    margin-top: 4px;
}

.progress-fill {
    height: 100%;
    background: #3b82f6;
    transition: width 0.3s;
}

/* Filters */
.filter {
    margin-bottom: 20px;
}

.filter select {
    padding: 10px 16px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 1rem;
    background: white;
    cursor: pointer;
}

/* Links */
.url {
    color: #3b82f6;
    text-decoration: none;
    word-break: break-all;
}

.url:hover {
    text-decoration: underline;
}

/* Grid Layouts */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 24px;
    margin-bottom: 24px;
}

.two-column {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    margin-bottom: 24px;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
    background-color: white;
    margin: 10% auto;
    padding: 30px;
    border-radius: 12px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.modal-header h2 {
    margin: 0;
    color: #1f2937;
}

.close-btn {
    font-size: 28px;
    font-weight: bold;
    color: #9ca3af;
    cursor: pointer;
    border: none;
    background: none;
}

.close-btn:hover {
    color: #374151;
}

/* Forms */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #374151;
}

.form-group input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 1rem;
}

.form-group input:focus {
    outline: none;
    border-color: #3b82f6;
}

.form-group input:disabled {
    background: #f3f4f6;
    color: #6b7280;
}

/* Buttons */
.btn-primary {
    background: #dc2626;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    cursor: pointer;
    width: 100%;
}

.btn-primary:hover {
    background: #b91c1c;
}

.add-site-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: #dc2626;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 20px;
    cursor: pointer;
    margin-left: 8px;
}

.add-site-btn:hover {
    background: #b91c1c;
}

.copy-btn {
    display: inline-block;
    margin-top: 10px;
    padding: 6px 12px;
    background: #3b82f6;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 0.875rem;
    cursor: pointer;
}

.copy-btn:hover {
    background: #2563eb;
}

.expand-btn {
    background: #f3f4f6;
    border: 1px solid #d1d5db;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    color: #374151;
    font-size: 0.875rem;
    transition: background 0.2s;
}

.expand-btn:hover {
    background: #e5e7eb;
}

/* Site Info */
.site-info {
    background: #f9fafb;
    padding: 15px;
    border-radius: 6px;
    margin-top: 15px;
}

.site-info h3 {
    margin: 0 0 10px 0;
    color: #1f2937;
    font-size: 0.875rem;
}

.site-info code {
    display: block;
    background: white;
    padding: 10px;
    border-radius: 4px;
    font-size: 0.875rem;
    word-break: break-all;
    margin-top: 5px;
}

/* Utilities */
.hidden-row {
    display: none;
}

/* Responsive */
@media (max-width: 900px) {
    .two-column {
        grid-template-columns: 1fr;
    }
}

/* Animations */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}
