* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 20px;
    color: #333;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    background: white;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

.header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 30px 40px;
    display: flex;
    align-items: center;
    gap: 20px;
}

.header img {
    width: 60px;
    height: 60px;
    filter: brightness(0) invert(1);
}

.header h1 {
    font-size: 32px;
    font-weight: 600;
    letter-spacing: -0.5px;
}

.content {
    padding: 40px;
}

.intro-section {
    margin-bottom: 30px;
    color: #495057;
}

.intro-section h2 {
    font-size: 24px;
    margin-bottom: 12px;
    color: #343a40;
    font-weight: 600;
}

.intro-section p {
    font-size: 15px;
    line-height: 1.6;
    color: #6c757d;
}

.intro-section a {
    color: #667eea;
    text-decoration: none;
    font-weight: 500;
}

.intro-section a:hover {
    text-decoration: underline;
}

.search-section {
    background: #fafbfc;
    border-radius: 12px;
    padding: 35px;
    margin-bottom: 30px;
    border: 1px solid #e9ecef;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.search-section h2 {
    font-size: 22px;
    margin-bottom: 25px;
    color: #343a40;
    font-weight: 600;
}

.search-group {
    margin-bottom: 25px;
}

.search-group:last-child {
    margin-bottom: 0;
}

.form-row {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: flex-end;
    margin-top: 15px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
}

.form-group-full {
    flex: 1;
}

.form-group-large {
    flex: 2;
}

.form-group label {
    font-size: 14px;
    font-weight: 500;
    color: #495057;
}

.form-group small {
    font-size: 12px;
    color: #6c757d;
    margin-top: 4px;
}

.form-section-title {
    font-size: 13px;
    font-weight: 600;
    color: #495057;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 15px;
    padding-bottom: 8px;
    border-bottom: 2px solid #dee2e6;
}

.search-box {
    padding: 12px 16px;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.3s ease;
    width: 100%;
    font-family: inherit;
}

.search-box-full {
    width: 100%;
}

.search-box:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.search-btn {
    padding: 12px 24px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.search-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(102, 126, 234, 0.5);
}

.search-btn:active {
    transform: translateY(0);
}

select.search-box {
    cursor: pointer;
    background-color: white;
}

#drivers-list {
    background: #e7f3ff;
    border: 1px solid #4a9eff;
    border-radius: 10px;
    padding: 20px 24px;
    margin: 25px 0;
    list-style: none;
    color: #004085;
    display: none;
}

#drivers-list li {
    padding: 6px 0;
    font-family: 'Courier New', monospace;
    font-size: 13px;
    line-height: 1.6;
}

.results-section {
    background: #fafbfc;
    border-radius: 12px;
    padding: 35px;
    border: 1px solid #e9ecef;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.results-section h2 {
    font-size: 22px;
    margin-bottom: 25px;
    color: #343a40;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.results-count {
    font-size: 14px;
    font-weight: 500;
    color: #6c757d;
    background: #e9ecef;
    padding: 4px 12px;
    border-radius: 20px;
}

.file-list {
    list-style: none;
    padding: 0;
}

.file-list li {
    padding: 14px 18px;
    margin: 10px 0;
    background: white;
    border-radius: 8px;
    transition: all 0.2s ease;
    border: 1px solid #e9ecef;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.file-list li:hover {
    background: #f8f9fa;
    transform: translateX(4px);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
    border-color: #667eea;
}

.file-list a {
    color: #667eea;
    text-decoration: none;
    font-weight: 500;
    word-break: break-all;
    font-size: 14px;
}

.file-list a:hover {
    color: #764ba2;
}

.pagination {
    display: flex;
    gap: 12px;
    margin-top: 30px;
    justify-content: center;
}

.pagination button {
    padding: 12px 28px;
    background: white;
    border: 2px solid #667eea;
    color: #667eea;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.pagination button:hover:not(:disabled) {
    background: #667eea;
    color: white;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(102, 126, 234, 0.3);
}

.pagination button:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    box-shadow: none;
}

/* Login Section Styles */
#loginSection {
    max-width: 450px;
    margin: 60px auto;
    background: white;
    border-radius: 12px;
    padding: 40px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
}

#loginSection h2 {
    font-size: 28px;
    margin-bottom: 12px;
    color: #343a40;
    font-weight: 600;
    text-align: center;
}

#loginSection p {
    font-size: 14px;
    color: #6c757d;
    text-align: center;
    margin-bottom: 30px;
}

#loginSection a {
    color: #667eea;
    text-decoration: none;
    font-weight: 500;
}

#loginSection a:hover {
    text-decoration: underline;
}

.login-form-group {
    margin-bottom: 20px;
}

.login-form-group label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: #495057;
    margin-bottom: 8px;
}

.login-form-group input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.3s ease;
    font-family: inherit;
}

.login-form-group input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

#recaptchaContainer {
    display: flex;
    justify-content: center;
    margin: 25px 0;
}

.login-btn {
    width: 100%;
    padding: 14px 24px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.login-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(102, 126, 234, 0.5);
}

.login-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.divider {
    text-align: center;
    margin: 25px 0;
    position: relative;
}

.divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: #dee2e6;
}

.divider span {
    background: white;
    padding: 0 15px;
    position: relative;
    color: #6c757d;
    font-size: 14px;
    font-weight: 500;
}

.google-btn {
    width: 100%;
    padding: 12px 24px;
    background: white;
    color: #444;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.google-btn:hover {
    background: #f8f9fa;
    border-color: #667eea;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.google-btn svg {
    width: 20px;
    height: 20px;
}

.login-error, .main-error {
    background: #f8d7da;
    color: #721c24;
    padding: 12px;
    border-radius: 6px;
    margin-bottom: 20px;
    font-size: 14px;
    display: none;
}

.main-error {
    border: 1px solid #f5c6cb;
}

.logout-btn {
    padding: 10px 20px;
    background: white;
    color: #667eea;
    border: 2px solid #667eea;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-left: auto;
}

.logout-btn:hover {
    background: #667eea;
    color: white;
}

.localhost-notice {
    background: #fff3cd;
    border: 1px solid #ffc107;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.localhost-notice p {
    margin: 8px 0 0 0;
    font-size: 13px;
}

.recaptcha-loading {
    text-align: center;
    color: #6c757d;
    font-size: 13px;
    margin: 10px 0;
}

.password-reset-link {
    margin-top: 20px;
    font-size: 13px;
}

.error-text {
    color: #d32f2f;
}

[hidden] {
    display: none !important;
}

@media (max-width: 768px) {
    .header {
        padding: 20px;
        flex-direction: column;
        text-align: center;
    }

    .header h1 {
        font-size: 24px;
    }

    .content {
        padding: 20px;
    }

    .intro-section h2 {
        font-size: 20px;
    }

    .intro-section p {
        font-size: 14px;
    }

    .search-section {
        padding: 24px;
    }

    .search-section h2 {
        font-size: 18px;
    }

    .results-section {
        padding: 24px;
    }

    .results-section h2 {
        font-size: 18px;
    }

    .form-row {
        flex-direction: column;
    }

    .form-group {
        width: 100%;
    }

    .search-box {
        width: 100%;
    }

    .search-btn {
        width: 100%;
    }

    .pagination button {
        flex: 1;
        padding: 12px 16px;
    }

    #loginSection {
        margin: 20px;
        padding: 30px 20px;
    }
}
