/* ===== CSS Variables ===== */
:root {
    /* Logo blue color: #1976D2 */
    --color-primary: #1976D2;
    --color-primary-dark: #1565C0;
    --color-secondary: #0f172a;
    --color-accent: #2196F3;
    --color-text: #1e293b;
    --color-text-light: #64748b;
    --color-bg: #ffffff;
    --color-bg-alt: #f8fafc;
    --color-border: #e2e8f0;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 1rem;
    --radius-xl: 1.5rem;
    --transition: 0.2s ease;
}

/* ===== Reset & Base ===== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 1rem;
    line-height: 1.6;
    color: var(--color-text);
    background: var(--color-bg);
}

a {
    color: inherit;
    text-decoration: none;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
}

/* ===== Utilities ===== */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.section-title {
    font-size: 2rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 0.5rem;
    color: var(--color-secondary);
}

.section-subtitle {
    text-align: center;
    color: var(--color-text-light);
    margin-bottom: 3rem;
}

/* ===== Buttons ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.875rem 1.75rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: var(--radius-md);
    border: 2px solid transparent;
    cursor: pointer;
    transition: all var(--transition);
}

.btn-primary {
    background: var(--color-primary);
    color: white;
}

.btn-primary:hover:not(:disabled) {
    background: var(--color-primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-primary:disabled {
    background: var(--color-text-light);
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.btn-secondary {
    background: white;
    color: var(--color-secondary);
    border-color: var(--color-border);
}

.btn-secondary:hover {
    border-color: var(--color-primary);
    color: var(--color-primary);
}

.btn-outline {
    background: transparent;
    color: var(--color-primary);
    border-color: var(--color-primary);
}

.btn-outline:hover {
    background: var(--color-primary);
    color: white;
}

.btn-large {
    padding: 1rem 2rem;
    font-size: 1.125rem;
}

/* ===== Header & Navigation ===== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--color-border);
    z-index: 1000;
    transition: background 0.4s ease, backdrop-filter 0.4s ease;
}

/* Progressive Blur on Scroll */
.header.scrolled {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(100px);
    -webkit-backdrop-filter: blur(100px);
}

.nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 9rem;
}

.logo {
    display: flex;
    align-items: center;
}

.logo img {
    height: 118px;
    width: 191px;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-link {
    font-weight: 500;
    color: var(--color-text-light);
    transition: color 0.3s ease, text-shadow 0.3s ease;
}

.nav-link:hover,
.nav-link.active {
    color: var(--color-primary);
    text-shadow: 0 0 20px rgba(25, 118, 210, 0.4);
}

.nav-cta {
    background: var(--color-primary);
    color: white !important;
    padding: 0.625rem 1.25rem;
    border-radius: var(--radius-md);
    transition: all 0.3s ease;
}

.nav-cta:hover {
    background: var(--color-primary-dark);
    box-shadow: 0 0 25px rgba(25, 118, 210, 0.5);
    text-shadow: none;
}

/* Login Icon Button (inside nav-menu) */
.nav-login-desktop {
    display: flex;
}

.nav-login-mobile {
    display: none;
}

.login-icon-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: transparent;
    border: 1px solid var(--color-border);
    border-radius: 50%;
    cursor: pointer;
    color: var(--color-text-light);
    transition: all var(--transition);
}

.login-icon-btn:hover {
    border-color: var(--color-primary);
    color: var(--color-primary);
    background: rgba(25, 118, 210, 0.05);
}

.login-icon-btn.authenticated {
    border-color: #16a34a;
    color: #16a34a;
    background: rgba(22, 163, 74, 0.08);
}

.login-icon-btn.authenticated:hover {
    background: rgba(22, 163, 74, 0.15);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 8px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.75rem;
}

.nav-toggle span {
    display: block;
    width: 32px;
    height: 3px;
    background: var(--color-secondary);
    border-radius: 2px;
    transition: all 0.35s cubic-bezier(0.68, -0.6, 0.32, 1.6);
    transform-origin: center;
}

/* ===== Hero Section ===== */
.hero {
    padding: 12rem 0 4rem;
    background: linear-gradient(135deg, var(--color-bg-alt) 0%, var(--color-bg) 100%);
}

.hero .container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.1;
    color: var(--color-secondary);
    margin-bottom: 1.5rem;
}

.hero-title .highlight {
    color: var(--color-primary);
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--color-text-light);
    margin-bottom: 2rem;
    max-width: 500px;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.hero-visual {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.hero-card {
    position: relative;
    display: flex;
    align-items: center;
    gap: 1.25rem;
    background: white;
    padding: 1.25rem 1.5rem;
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
    box-shadow: var(--shadow-md);
    cursor: pointer;
    overflow: hidden;
    transition: all 0.3s ease;
    opacity: 0;
    transform: translateX(40px);
    animation: slideInFloat 0.6s ease forwards;
}

.hero-card:nth-child(1) { animation-delay: 0.1s; margin-left: 0; }
.hero-card:nth-child(2) { animation-delay: 0.3s; margin-left: 2rem; }
.hero-card:nth-child(3) { animation-delay: 0.5s; margin-left: 4rem; }

@keyframes slideInFloat {
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Mouse spotlight effect */
.hero-card::before {
    content: '';
    position: absolute;
    width: 250px;
    height: 250px;
    background: radial-gradient(circle, rgba(25, 118, 210, 0.15) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
    transform: translate(-50%, -50%);
    left: var(--x, 50%);
    top: var(--y, 50%);
}

.hero-card:hover::before {
    opacity: 1;
}

.hero-card:hover {
    transform: translateY(-4px) translateX(10px);
    box-shadow: var(--shadow-lg), 0 0 30px rgba(25, 118, 210, 0.1);
    border-color: var(--color-primary);
}

.hero-card-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    flex-shrink: 0;
    position: relative;
    z-index: 1;
    transition: all 0.3s ease;
}

.hero-card-icon svg {
    width: 24px;
    height: 24px;
}

/* Pulse animation */
.hero-card-icon::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 12px;
    background: var(--color-primary);
    animation: heroPulse 2.5s ease-in-out infinite;
    z-index: -1;
}

.hero-card:nth-child(1) .hero-card-icon::after { animation-delay: 0s; }
.hero-card:nth-child(2) .hero-card-icon::after { animation-delay: 0.4s; }
.hero-card:nth-child(3) .hero-card-icon::after { animation-delay: 0.8s; }

@keyframes heroPulse {
    0%, 100% { transform: scale(1); opacity: 0.4; }
    50% { transform: scale(1.3); opacity: 0; }
}

.hero-card:hover .hero-card-icon {
    transform: scale(1.1);
    box-shadow: 0 0 20px rgba(25, 118, 210, 0.4);
}

.hero-card:hover .hero-card-icon::after {
    animation: none;
    opacity: 0;
}

.hero-card-text {
    font-weight: 600;
    color: var(--color-secondary);
    position: relative;
    z-index: 1;
}

/* ===== Services Preview ===== */
.services-preview {
    padding: 3rem 0;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.service-card {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
    transition: all var(--transition);
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: var(--color-primary);
}

.service-icon {
    width: 48px;
    height: 48px;
    margin-bottom: 1rem;
    color: var(--color-primary);
}

.service-icon svg {
    width: 100%;
    height: 100%;
}

.service-card h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--color-secondary);
}

.service-card p {
    font-size: 0.9375rem;
    color: var(--color-text-light);
}

.services-cta {
    text-align: center;
}

/* ===== Why Me Section ===== */
.why-me {
    padding: 5rem 0;
    background: var(--color-bg-alt);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-top: 3rem;
}

.feature {
    text-align: center;
}

.feature-number {
    font-size: 3rem;
    font-weight: 700;
    color: var(--color-primary);
    opacity: 0.3;
    margin-bottom: 1rem;
}

.feature h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--color-secondary);
}

.feature p {
    font-size: 0.9375rem;
    color: var(--color-text-light);
}

/* ===== CTA Section ===== */
.cta-section {
    padding: 5rem 0;
    background: var(--color-secondary);
}

.cta-content {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.cta-content h2 {
    font-size: 2rem;
    font-weight: 700;
    color: white;
    margin-bottom: 1rem;
}

.cta-content p {
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 2rem;
}

/* ===== Page Header ===== */
.page-header {
    padding: 10rem 0 2rem;
    background: var(--color-bg-alt);
    text-align: center;
}

.page-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--color-secondary);
    margin-bottom: 0.5rem;
}

.page-header p {
    color: var(--color-text-light);
    font-size: 1.125rem;
}

/* ===== Services Detail ===== */
.services-detail {
    padding: 4rem 0;
}

.service-detail-card {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 2rem;
    padding: 2.5rem;
    margin-bottom: 2rem;
    background: white;
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
    transition: all var(--transition);
}

.service-detail-card:hover {
    box-shadow: var(--shadow-lg);
    border-color: var(--color-primary);
}

.service-detail-icon {
    width: 64px;
    height: 64px;
    flex-shrink: 0;
    color: var(--color-primary);
}

.service-detail-icon svg {
    width: 100%;
    height: 100%;
}

.service-detail-content h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--color-secondary);
    margin-bottom: 0.75rem;
}

.service-detail-content > p {
    color: var(--color-text-light);
    margin-bottom: 1rem;
}

.service-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
}

.service-list li {
    position: relative;
    padding-left: 1.5rem;
    color: var(--color-text);
}

.service-list li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--color-primary);
    font-weight: 600;
}

/* ===== About Page ===== */
.about-content {
    padding: 4rem 0;
}

.about-grid {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 2rem;
    align-items: start;
}

.about-photo {
    width: 220px;
    height: 257px;
    object-fit: cover;
    border-radius: var(--radius-lg);
    margin-top: 2.5rem;
}

.about-text h2 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--color-secondary);
    margin-bottom: 1rem;
}

.about-text p {
    color: var(--color-text-light);
    margin-bottom: 1rem;
}

.about-values {
    padding: 4rem 0;
    background: var(--color-bg-alt);
}

.values-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-top: 3rem;
}

.value-card {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-lg);
    text-align: center;
}

.value-icon {
    width: 48px;
    height: 48px;
    margin: 0 auto 1rem;
    color: var(--color-primary);
}

.value-icon svg {
    width: 100%;
    height: 100%;
}

.value-card h3 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--color-secondary);
    margin-bottom: 0.5rem;
}

.value-card p {
    font-size: 0.9375rem;
    color: var(--color-text-light);
}

/* ===== Contact Page ===== */
.contact-section {
    padding: 4rem 0;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--color-secondary);
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 0.875rem 1rem;
    font-size: 1rem;
    font-family: inherit;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    background: white;
    transition: border-color var(--transition);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--color-primary);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.form-checkbox {
    flex-direction: row;
    align-items: flex-start;
    gap: 0.75rem;
}

.form-checkbox input {
    width: auto;
    margin-top: 0.25rem;
}

.form-checkbox label {
    font-size: 0.875rem;
    font-weight: 400;
    color: var(--color-text-light);
}

.form-checkbox a {
    color: var(--color-primary);
    text-decoration: underline;
}

/* ===== Contact Section ===== */
.contact-section .container {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 3rem;
    align-items: start;
}

.contact-form-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--color-border);
}

.contact-form-card h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-secondary);
    margin-bottom: 0.5rem;
}

.contact-form-card > p {
    color: var(--color-text-light);
    margin-bottom: 2rem;
}

/* WhatsApp Card in Sidebar */
.info-card.whatsapp-card {
    background: white;
    padding: 2.5rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
}

.info-card.whatsapp-card h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-secondary);
    margin-bottom: 0.5rem;
}

.info-card.whatsapp-card p {
    color: var(--color-text-light);
    margin-bottom: 2rem;
}

/* Required field indicators */
.required-star {
    color: var(--color-text-light);
    transition: color var(--transition);
}

.required-star.error {
    color: #ef4444;
    font-weight: 700;
}

/* Form status messages */
.form-status {
    padding: 1rem;
    border-radius: var(--radius-md);
    margin-bottom: 1rem;
    font-size: 0.9375rem;
}

.form-status.error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #991b1b;
}

.form-status.success {
    background: #ecfdf5;
    border: 1px solid #a7f3d0;
    color: #065f46;
}

.form-status.blocked {
    background: #fef3c7;
    border: 1px solid #fcd34d;
    color: #92400e;
}

/* Character counter */
.char-counter {
    display: block;
    text-align: right;
    font-size: 0.8125rem;
    color: var(--color-text-light);
    margin-top: 0.25rem;
}

.char-counter.warning {
    color: #f59e0b;
}

.char-counter.limit {
    color: #ef4444;
    font-weight: 500;
}

.btn-whatsapp {
    background: #25D366;
    color: white;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    width: 100%;
}

.btn-whatsapp:hover {
    background: #1da851;
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-icon {
    width: 20px;
    height: 20px;
}

.contact-info-sidebar {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.info-card {
    background: white;
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
}

.info-card h3 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--color-secondary);
    margin-bottom: 1rem;
}

/* ===== Upload Card ===== */
.upload-card {
    background: white;
    padding: 2.5rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    min-height: 407px;
    display: flex;
    flex-direction: column;
}

/* Upload content container (works in both card and inline) */
.upload-content {
    display: flex;
    flex-direction: column;
    flex: 1;
}

/* Inline upload area (inside form, for mobile) */
.upload-area-inline {
    display: none;
}

@media (max-width: 1024px) {
    /* Hide card in sidebar on tablet/mobile */
    .upload-card {
        display: none;
    }

    /* Show inline area on tablet/mobile */
    .upload-area-inline {
        display: block;
        margin-top: 0.5rem;
        padding: 1.25rem;
        background: var(--color-bg-alt);
        border-radius: var(--radius-md);
        border: 1px solid var(--color-border);
    }

    /* More space before submit button on mobile */
    .contact-form .btn-large {
        margin-top: 1.5rem;
    }

    .upload-area-inline .upload-content {
        min-height: auto;
    }

    .upload-area-inline h3 {
        font-size: 1rem;
        margin-bottom: 0.75rem;
    }

    .upload-area-inline .upload-dropzone {
        display: none;
    }

    .upload-area-inline .upload-footer {
        margin-top: 0;
    }

    .upload-area-inline .upload-meta {
        margin-bottom: 0.75rem;
    }
}

.upload-card h3 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--color-secondary);
    margin-bottom: 1rem;
}

/* Drag & Drop Zone */
.upload-dropzone {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 1.5rem;
    border: 2px dashed var(--color-border);
    border-radius: var(--radius-md);
    background: var(--color-bg-alt);
    cursor: pointer;
    transition: all var(--transition);
    flex: 1;
    min-height: 80px;
}

/* Shrink dropzone when files are present */
.upload-card.has-files .upload-dropzone {
    flex: 0;
    padding: 1rem;
}

.upload-dropzone:hover {
    border-color: var(--color-primary);
    background: rgba(25, 118, 210, 0.03);
}

.upload-dropzone.dragover {
    border-color: var(--color-primary);
    background: rgba(25, 118, 210, 0.08);
    border-style: solid;
}

.upload-icon {
    width: 32px;
    height: 32px;
    color: var(--color-text-light);
    margin-bottom: 0.5rem;
    transition: color var(--transition);
}

.upload-dropzone:hover .upload-icon,
.upload-dropzone.dragover .upload-icon {
    color: var(--color-primary);
}

.upload-dropzone p {
    font-size: 0.8125rem;
    color: var(--color-text-light);
    margin: 0;
}

/* Upload Meta (like char-counter) */
.upload-meta {
    display: block;
    text-align: right;
    font-size: 0.8125rem;
    color: var(--color-text-light);
    margin-top: 0.25rem;
}

.upload-meta.error {
    color: #dc2626;
}

/* Upload Footer (pushed to bottom) */
.upload-footer {
    margin-top: auto;
}

/* Upload Buttons */
.upload-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 1rem;
}

.upload-btn,
.camera-btn {
    width: 100%;
    padding: 0.75rem 1rem;
    font-size: 0.9375rem;
}

.btn-icon-sm {
    width: 18px;
    height: 18px;
    margin-right: 0.5rem;
}

/* Camera button hidden on desktop */
.camera-btn {
    display: none;
}

/* File List */
.file-list {
    list-style: none;
    padding: 0;
    margin: 0.75rem 0 0;
    overflow: hidden;
}

.file-list:empty {
    display: none;
}

.file-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.625rem;
    background: var(--color-bg-alt);
    border-radius: var(--radius-sm);
    margin-bottom: 0.375rem;
    transition: background var(--transition);
}

.file-item:last-child {
    margin-bottom: 0;
}

.file-item:hover {
    background: #f1f5f9;
}

.file-item-icon {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    color: var(--color-primary);
}

.file-item-info {
    flex: 1;
    min-width: 0;
    overflow: hidden;
}

.file-item-name {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--color-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.file-item-size {
    font-size: 0.6875rem;
    color: var(--color-text-light);
}

.file-item-remove {
    width: 22px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    border-radius: var(--radius-sm);
    color: var(--color-text-light);
    cursor: pointer;
    transition: all var(--transition);
    flex-shrink: 0;
}

.file-item-remove:hover {
    background: #fee2e2;
    color: #dc2626;
}

.file-item-remove svg {
    width: 14px;
    height: 14px;
}

/* Upload Progress */
.upload-progress {
    margin-top: 1rem;
}

.upload-progress-text {
    font-size: 0.8125rem;
    color: var(--color-text);
    margin-bottom: 0.5rem;
    display: flex;
    justify-content: space-between;
}

.upload-progress-bar {
    height: 8px;
    background: var(--color-border);
    border-radius: 4px;
    overflow: hidden;
}

.upload-progress-fill {
    height: 100%;
    background: var(--color-primary);
    border-radius: 4px;
    transition: width 0.2s ease;
    width: 0%;
}

/* File validation error state */
.file-item.error {
    background: #fef2f2;
    border: 1px solid #fecaca;
}

.file-item.error .file-item-name {
    color: #991b1b;
}

.file-item-error {
    font-size: 0.75rem;
    color: #dc2626;
}

/* Upload status in form */
.form-status.uploading {
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    color: #1e40af;
}

/* Tablet/Mobile: Hide dropzone, show camera button */
@media (max-width: 1024px), (pointer: coarse) {
    .upload-dropzone {
        display: none;
    }

    .camera-btn {
        display: inline-flex;
    }
}

/* ===== FAQ Section ===== */
.faq-section {
    padding: 4rem 0;
    background: var(--color-bg-alt);
}

.faq-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    margin-top: 3rem;
}

.faq-item {
    background: white;
    padding: 1.5rem;
    border-radius: var(--radius-lg);
}

.faq-item h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-secondary);
    margin-bottom: 0.5rem;
}

.faq-item p {
    font-size: 0.9375rem;
    color: var(--color-text-light);
}

/* ===== Legal Pages (Impressum, Datenschutz) ===== */
.legal-content {
    padding: 3rem 0 5rem;
}

.legal-content .container {
    max-width: 800px;
}

.legal-section {
    margin-bottom: 2.5rem;
}

.legal-section h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-secondary);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--color-primary);
}

.legal-section h3 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--color-secondary);
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}

.legal-section p {
    color: var(--color-text);
    font-size: 0.875rem;
    margin-bottom: 1rem;
    line-height: 1.7;
}

.legal-section a {
    color: var(--color-primary);
    text-decoration: underline;
}

.legal-section a:hover {
    color: var(--color-primary-dark);
}

.legal-list {
    margin: 1rem 0;
    padding-left: 1.5rem;
}

.legal-list li {
    position: relative;
    padding-left: 1rem;
    margin-bottom: 0.5rem;
    color: var(--color-text);
    font-size: 0.875rem;
    list-style: disc;
}

/* ===== Footer ===== */
.footer {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    color: white;
    padding: 3rem 0 2rem;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-brand {
    flex: 1;
}

.footer-logo {
    display: inline-block;
    margin-bottom: 1rem;
}

.footer-logo img {
    height: 50px;
    width: auto;
}

.footer-brand h4 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: white;
}

.footer-brand p {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.875rem;
    max-width: 300px;
    line-height: 1.6;
}

.footer-right {
    display: flex;
    gap: 3rem;
    align-items: flex-start;
}

.footer-links ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.875rem;
    transition: color var(--transition);
}

.footer-links a:hover {
    color: var(--color-primary);
}

.footer-social {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.footer-social a {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    font-size: 0.875rem;
    transition: color var(--transition);
}

.footer-social a:hover {
    color: var(--color-primary);
}

.footer-social svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
}

.footer-bottom {
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-bottom p {
    color: rgba(255, 255, 255, 0.4);
    font-size: 0.8125rem;
}

.footer-bottom-links {
    display: flex;
    gap: 1.5rem;
}

.footer-bottom-links a {
    color: rgba(255, 255, 255, 0.4);
    text-decoration: none;
    font-size: 0.8125rem;
    transition: color var(--transition);
}

.footer-bottom-links a:hover {
    color: white;
}

/* ===== Responsive Design ===== */
@media (max-width: 1024px) {
    .hero .container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-subtitle {
        margin: 0 auto 2rem;
    }

    .hero-buttons {
        justify-content: center;
    }

    .hero-visual {
        display: none;
    }

    .hero-title {
        font-size: 2.75rem;
    }

    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .features-grid,
    .values-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .about-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .about-image-placeholder {
        margin: 0 auto;
    }

    .contact-grid {
        grid-template-columns: 1fr;
    }

    .contact-section .container {
        grid-template-columns: 1fr;
    }

    .footer-content {
        flex-wrap: wrap;
    }

    .footer-right {
        gap: 2rem;
    }
}

@media (max-width: 768px) {
    /* Cover to prevent menu items showing over header */
    .nav::before {
        content: '';
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        height: 9rem;
        background: rgba(255, 255, 255, 0.3);
        backdrop-filter: blur(8px);
        -webkit-backdrop-filter: blur(8px);
        z-index: 10;
        transition: all 0.4s ease;
    }

    /* Progressive blur on scroll for the cover */
    .header.scrolled .nav::before {
        background: rgba(255, 255, 255, 0.7);
        backdrop-filter: blur(100px);
        -webkit-backdrop-filter: blur(100px);
    }

    /* Ensure logo and toggle are above the cover */
    .logo {
        position: relative;
        z-index: 11;
    }

    .nav-toggle {
        display: flex;
        position: relative;
        z-index: 11;
    }

    /* Menu stays below the cover */
    .nav-menu {
        position: fixed;
        top: 9rem;
        left: 0;
        right: 0;
        background: white;
        flex-direction: column;
        padding: 2.5rem;
        gap: 0.5rem;
        border-bottom: 1px solid var(--color-border);
        box-shadow: var(--shadow-lg);
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        z-index: 5;
    }

    .nav-menu.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }

    /* Staggered menu item animations */
    .nav-menu li {
        opacity: 0;
        transform: translateY(20px);
        transition: opacity 0.3s ease, transform 0.3s ease;
    }

    .nav-menu.active li {
        opacity: 1;
        transform: translateY(0);
    }

    .nav-menu li:nth-child(1) { transition-delay: 0.05s; }
    .nav-menu li:nth-child(2) { transition-delay: 0.10s; }
    .nav-menu li:nth-child(3) { transition-delay: 0.15s; }
    .nav-menu li:nth-child(4) { transition-delay: 0.20s; }
    .nav-menu li:nth-child(5) { transition-delay: 0.25s; }
    .nav-menu li:nth-child(6) { transition-delay: 0.30s; }

    .nav-menu .nav-link {
        display: block;
        padding: 1rem 1.5rem;
        font-size: 1.25rem;
        font-weight: 500;
        border-radius: var(--radius-md);
        transition: background var(--transition), color 0.3s ease, text-shadow 0.3s ease;
    }

    .nav-menu .nav-link:hover {
        background: var(--color-bg-alt);
    }

    .nav-menu .nav-cta {
        margin-top: 0.5rem;
        text-align: center;
        padding: 1.25rem 1.5rem;
        font-size: 1.25rem;
    }

    /* Smooth Hamburger to X animation */
    .nav-toggle.active span:nth-child(1) {
        transform: translateY(11px) rotate(135deg);
    }

    .nav-toggle.active span:nth-child(2) {
        transform: scaleX(0);
        opacity: 0;
    }

    .nav-toggle.active span:nth-child(3) {
        transform: translateY(-11px) rotate(-135deg);
    }

    .hero-title {
        font-size: 2.25rem;
    }

    .services-grid {
        grid-template-columns: 1fr;
    }

    .features-grid,
    .values-grid {
        grid-template-columns: 1fr;
    }

    .service-detail-card {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .service-list {
        grid-template-columns: 1fr;
        text-align: left;
    }

    .experience-grid {
        flex-direction: column;
        gap: 2rem;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .faq-grid {
        grid-template-columns: 1fr;
    }

    .footer-content {
        flex-direction: column;
        gap: 2rem;
    }

    .footer-brand {
        text-align: center;
    }

    .footer-brand p {
        max-width: 100%;
    }

    .footer-right {
        width: 100%;
        justify-content: center;
        flex-wrap: wrap;
        gap: 2rem;
    }

    .footer-links ul {
        align-items: center;
    }

    .footer-social {
        align-items: center;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .footer-bottom-links {
        justify-content: center;
    }
}

/* ============================================
   Error Pages (404, 500, etc.)
   ============================================ */
.header-minimal .nav-toggle,
.header-minimal .nav-menu {
    display: none;
}

.error-page {
    min-height: calc(100vh - 200px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4rem 0;
    overflow: visible;
}

.error-content {
    text-align: center;
    max-width: 500px;
    padding: 0 1rem;
}

.error-code {
    font-size: clamp(5rem, 15vw, 10rem);
    font-weight: 800;
    color: var(--color-primary);
    line-height: 1;
    margin-bottom: 1.5rem;
}

.error-content h1 {
    font-size: 1.75rem;
    margin-bottom: 1rem;
    color: var(--color-text);
}

.error-content p {
    font-size: 1.1rem;
    color: var(--color-text-light);
    margin-bottom: 2rem;
}

.error-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

.footer.footer-minimal {
    padding: 1.5rem 0;
    background: var(--color-secondary);
}

.footer.footer-minimal .footer-bottom-minimal {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
}

.footer.footer-minimal .footer-bottom-minimal p {
    margin: 0;
    color: rgba(255, 255, 255, 0.7);
}

.footer.footer-minimal .footer-legal {
    display: flex;
    gap: 1.5rem;
}

.footer.footer-minimal .footer-legal a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: color 0.2s;
}

.footer.footer-minimal .footer-legal a:hover {
    color: white;
}

@media (max-width: 480px) {
    /* Compact mobile layout - State of the Art */
    .container {
        padding: 0 1rem;
    }

    /* Page header: lighter and smaller */
    .page-header h1 {
        font-size: 1.75rem;
        font-weight: 600;
    }

    .page-header p {
        font-size: 0.9375rem;
    }

    /* All cards: reduced padding, smaller radius */
    .contact-form-card,
    .info-card.whatsapp-card,
    .service-detail-card {
        padding: 1.25rem;
        border-radius: var(--radius-md);
        margin-left: -0.25rem;
        margin-right: -0.25rem;
    }

    .service-card,
    .value-card {
        padding: 1.25rem;
        border-radius: var(--radius-md);
    }

    .info-card,
    .faq-item {
        padding: 1rem;
        border-radius: var(--radius-md);
    }

    /* Headings: slightly smaller */
    .contact-form-card h2,
    .info-card.whatsapp-card h2 {
        font-size: 1.25rem;
    }

    .service-card h3,
    .value-card h3,
    .faq-item h3 {
        font-size: 1rem;
    }

    /* Descriptions: tighter spacing */
    .contact-form-card > p,
    .info-card.whatsapp-card p {
        margin-bottom: 1.5rem;
        font-size: 0.9375rem;
    }

    /* Section spacing */
    .contact-section,
    .services-detail,
    .about-content,
    .about-values,
    .faq-section {
        padding: 2.5rem 0;
    }

    /* Prevent horizontal overflow */
    .contact-form-card {
        overflow: hidden;
    }

    .contact-form {
        max-width: 100%;
        overflow: hidden;
    }

    .upload-area-inline {
        overflow: hidden;
        box-sizing: border-box;
    }

    .upload-area-inline .upload-content,
    .upload-area-inline .file-list,
    .upload-area-inline .file-item {
        max-width: 100%;
        box-sizing: border-box;
    }

    .file-item-name {
        text-overflow: ellipsis;
    }

    .error-code {
        font-size: 5rem;
    }

    .error-content h1 {
        font-size: 1.25rem;
    }

    .footer.footer-minimal .footer-bottom-minimal {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
}

/* ============================================
   Login Page (Compact)
   ============================================ */
.login-page {
    min-height: calc(100vh - 160px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6rem 1rem 2rem;
    background: var(--color-bg-alt);
}

.login-page .container {
    display: flex;
    justify-content: center;
}

.login-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--color-border);
    width: 100%;
    max-width: 340px;
}

.login-card h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-secondary);
    margin-bottom: 1rem;
    text-align: center;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.login-form .form-group {
    margin-bottom: 0;
}

.login-form .form-group label {
    font-size: 0.875rem;
    margin-bottom: 0.25rem;
}

.login-form .form-group input {
    padding: 0.5rem 0.75rem;
    font-size: 0.9375rem;
}

.login-form .btn-block {
    margin-top: 0.25rem;
    padding: 0.625rem 1rem;
}

.btn-block {
    width: 100%;
}

.form-hint {
    display: block;
    font-size: 0.75rem;
    color: var(--color-text-light);
    margin-top: 0.25rem;
}

.form-info {
    color: var(--color-text);
    margin-bottom: 0.75rem;
    padding: 0.75rem;
    background: var(--color-bg-alt);
    border-radius: var(--radius-md);
    font-size: 0.8125rem;
    line-height: 1.4;
}

.login-links {
    text-align: center;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--color-border);
}

.login-links a {
    color: var(--color-primary);
    font-size: 0.875rem;
}

.login-links a:hover {
    text-decoration: underline;
}

/* Password Criteria Checklist */
.password-criteria {
    list-style: none;
    padding: 0;
    margin: 0.5rem 0 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem 0.75rem;
}

.password-criteria li {
    font-size: 0.75rem;
    color: var(--color-text-light);
    display: flex;
    align-items: center;
    gap: 0.25rem;
    transition: color 0.2s ease;
}

.password-criteria li.valid {
    color: #16a34a;
}

.password-criteria li .criterion-icon::before {
    content: "○";
    font-size: 0.625rem;
}

.password-criteria li.valid .criterion-icon::before {
    content: "✓";
    font-weight: 600;
}

/* MFA QR Code Display */
.mfa-qr-container {
    display: flex;
    justify-content: center;
    padding: 1rem;
    background: white;
    border-radius: var(--radius-md);
    border: 1px solid var(--color-border);
    margin-bottom: 0.75rem;
}

.mfa-qr-container img {
    display: block;
    max-width: 100%;
    height: auto;
}

/* MFA Manual Entry Toggle */
.mfa-manual-entry {
    margin-bottom: 0.75rem;
}

.mfa-manual-entry summary {
    cursor: pointer;
    color: var(--color-text-light);
    font-size: 0.8125rem;
    padding: 0.375rem 0;
    user-select: none;
}

.mfa-manual-entry summary:hover {
    color: var(--color-primary);
}

.mfa-manual-entry[open] summary {
    margin-bottom: 0.5rem;
}

/* MFA Setup Secret Display */
.mfa-setup-secret {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--color-bg-alt);
    padding: 0.75rem;
    border-radius: var(--radius-md);
    margin-bottom: 0;
    border: 1px solid var(--color-border);
}

.mfa-setup-secret code {
    flex: 1;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
    font-size: 0.75rem;
    word-break: break-all;
    color: var(--color-secondary);
}

.btn-copy {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: white;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    color: var(--color-text-light);
    transition: all var(--transition);
    flex-shrink: 0;
}

.btn-copy:hover {
    color: var(--color-primary);
    border-color: var(--color-primary);
}

.btn-copy.copied {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: white;
}

/* Login Form Status Messages */
.login-card .form-status {
    margin-bottom: 0.75rem;
    padding: 0.625rem 0.75rem;
    font-size: 0.8125rem;
}

@media (max-width: 400px) {
    .login-page {
        padding: 5rem 0.75rem 1.5rem;
    }

    .login-card {
        padding: 1.25rem;
        max-width: 100%;
    }

    .login-card h1 {
        font-size: 1.375rem;
    }

    .mfa-setup-secret code {
        font-size: 0.6875rem;
    }

    .password-criteria {
        flex-direction: column;
        gap: 0.125rem;
    }
}

/* ============================================
   Login Modal (Header Popup)
   ============================================ */
.login-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

.login-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.login-modal {
    position: absolute;
    top: 5.5rem;
    right: 1.5rem;
    background: white;
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    box-shadow: var(--shadow-xl);
    width: 100%;
    max-width: 320px;
    transform: translateY(-10px);
    opacity: 0;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

/* Position modal within container on larger screens */
@media (min-width: 1248px) {
    .login-modal {
        right: calc((100vw - 1200px) / 2);
    }
}

.login-modal-overlay.active .login-modal {
    transform: translateY(0);
    opacity: 1;
}

.login-modal-close {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    font-size: 1.5rem;
    color: var(--color-text-light);
    cursor: pointer;
    border-radius: var(--radius-sm);
    transition: all var(--transition);
}

.login-modal-close:hover {
    background: var(--color-bg-alt);
    color: var(--color-text);
}

.login-modal h2 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--color-secondary);
    margin-bottom: 1rem;
    padding-right: 1.5rem;
}

.login-modal .login-form {
    gap: 1rem;
}

.login-modal .form-group {
    gap: 0.1rem;
}

.login-modal .form-group label {
    font-size: 0.8125rem;
}

.login-modal .form-group input {
    padding: 0.5rem 0.75rem;
    font-size: 0.9375rem;
}

.login-modal .btn-block {
    margin-top: 1rem;
    margin-bottom: 0.2rem;
    padding: 0.625rem 1rem;
    font-size: 0.9375rem;
}

.login-modal .form-status {
    margin-bottom: 0.75rem;
    padding: 0.5rem 0.75rem;
    font-size: 0.8125rem;
}

.login-modal .login-links {
    margin-top: 0.75rem;
    padding-top: 0.75rem;
}

.login-modal .login-links a {
    font-size: 0.8125rem;
}

.login-modal .form-hint {
    font-size: 0.6875rem;
}

.login-modal .form-info {
    font-size: 0.8125rem;
    margin-bottom: 0.75rem;
    padding: 0.5rem 0.75rem;
}

/* Modal-specific: Password Criteria */
.login-modal .password-criteria {
    gap: 0.125rem 0.5rem;
}

.login-modal .password-criteria li {
    font-size: 0.6875rem;
}

/* Modal-specific: MFA QR Code */
.login-modal .mfa-qr-container {
    padding: 0.75rem;
    margin-bottom: 0.5rem;
}

.login-modal .mfa-qr-container img {
    width: 140px;
    height: 140px;
}

/* Modal-specific: MFA Manual Entry */
.login-modal .mfa-manual-entry {
    margin-bottom: 0.5rem;
}

.login-modal .mfa-manual-entry summary {
    font-size: 0.75rem;
}

.login-modal .mfa-setup-secret {
    padding: 0.5rem;
}

.login-modal .mfa-setup-secret code {
    font-size: 0.6875rem;
}

.login-modal .btn-copy {
    width: 28px;
    height: 28px;
}

.login-modal .btn-copy svg {
    width: 14px;
    height: 14px;
}

/* Mobile adjustments for login modal */
@media (max-width: 768px) {
    /* Hide desktop login, show mobile login */
    .nav-login-desktop {
        display: none;
    }

    .nav-login-mobile {
        display: block !important;
    }

    .login-modal {
        top: 50%;
        left: 50%;
        right: auto;
        transform: translate(-50%, -50%) translateY(-10px);
        opacity: 0;
        width: calc(100% - 2rem);
        max-width: 320px;
    }

    .login-modal-overlay.active .login-modal {
        transform: translate(-50%, -50%) translateY(0);
        opacity: 1;
    }
}
