/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Light Theme */
    --bg-primary: #ffffff;
    --bg-secondary: #f8f9fa;
    --bg-card: #ffffff;
    --text-primary: #1a1a1a;
    --text-secondary: #6c757d;
    --accent: #4f46e5;
    --accent-hover: #4338ca;
    --border: #e5e7eb;
    --shadow: rgba(0, 0, 0, 0.1);
    --strength-weak: #ef4444;
    --strength-medium: #f59e0b;
    --strength-strong: #10b981;
    --strength-very-strong: #059669;
}

[data-theme="dark"] {
    --bg-primary: #0f172a;
    --bg-secondary: #1e293b;
    --bg-card: #1e293b;
    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
    --accent: #6366f1;
    --accent-hover: #818cf8;
    --border: #334155;
    --shadow: rgba(0, 0, 0, 0.3);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Screen reader only - visually hidden but accessible */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.header {
    background: var(--bg-card);
    border-bottom: 1px solid var(--border);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 4px var(--shadow);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
}

.header-buttons {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.logo-img {
    height: 40px;
    width: auto;
    max-width: 200px;
    object-fit: contain;
}

/* Fallback for logo text if image doesn't load */
.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--accent);
    white-space: nowrap;
}

.theme-toggle {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 0.5rem 1rem;
    cursor: pointer;
    font-size: 1.2rem;
    transition: background-color 0.3s ease, color 0.3s ease, transform 0.3s ease;
    will-change: transform;
    transform: translateZ(0);
}

.theme-toggle:hover {
    background: var(--accent);
    color: white;
    transform: translateZ(0) scale(1.05);
}

/* Menu Toggle Button */
.menu-toggle {
    display: none;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 0.5rem 0.75rem;
    cursor: pointer;
    font-size: 1.5rem;
    color: var(--text-primary);
    transition: background-color 0.3s ease, color 0.3s ease;
    z-index: 101;
    min-width: 44px;
    min-height: 44px;
    will-change: background-color;
    transform: translateZ(0);
    align-items: center;
    justify-content: center;
}

/* Show menu toggle on mobile immediately to prevent flash */
@media (max-width: 768px) {
    .header-buttons {
        gap: 0.5rem;
    }

    .menu-toggle {
        display: block;
    }
}

.menu-toggle:hover {
    background: var(--accent);
    color: white;
}

.menu-toggle.active {
    background: var(--accent);
    color: white;
}

/* Navigation */
.logo-link {
    text-decoration: none;
    color: inherit;
}

.nav {
    display: flex;
    gap: 1.5rem;
    align-items: center;
    flex-wrap: wrap;
}

/* Hide menu completely on mobile by default - no flash */
@media (max-width: 768px) {
    .nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--bg-card);
        border-bottom: 1px solid var(--border);
        box-shadow: 0 4px 6px var(--shadow);
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        padding: 0;
        z-index: 99;
    }

    .nav.active {
        display: flex;
        padding: 1rem 0;
    }
}

.nav a {
    color: var(--text-primary);
    opacity: 0.8;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease, opacity 0.3s ease;
    padding: 0.5rem 0;
}

.nav a:hover {
    color: var(--accent);
    opacity: 1;
}

/* Active link with gradient on desktop */
@media (min-width: 769px) {
    .nav a.active {
        background: linear-gradient(135deg, var(--accent), #8b5cf6);
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
        background-clip: text;
        font-weight: 600;
        position: relative;
    }

    .nav a.active::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 0;
        right: 0;
        height: 2px;
        background: linear-gradient(135deg, var(--accent), #8b5cf6);
        border-radius: 2px;
    }
}

/* Mobile nav link styles */
@media (max-width: 768px) {
    .nav a {
        display: block;
        padding: 0.75rem 1.5rem;
        color: var(--text-primary);
        border-bottom: 1px solid var(--border);
    }

    .nav a:last-child {
        border-bottom: none;
    }

    .nav a:hover {
        background: var(--bg-secondary);
        color: var(--accent);
    }

    .nav a.active {
        background: var(--accent);
        color: white;
        font-weight: 600;
    }

    .nav a.active:hover {
        background: var(--accent-hover);
    }
}

/* Hero Section */
.hero {
    padding: 3rem 0;
}

.hero-title {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, var(--accent), #8b5cf6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    text-align: center;
    font-size: 1.1rem;
    color: var(--text-primary);
    opacity: 0.85;
    margin-bottom: 2rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

/* Ad Containers */
.ad-container {
    width: 100%;
    margin: 2rem 0;
    min-height: 90px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-secondary);
    border: 1px dashed var(--border);
    border-radius: 8px;
    padding: 1rem;
}

.ad-top {
    min-height: 90px;
}

.ad-middle {
    min-height: 250px;
}

.ad-bottom {
    min-height: 90px;
}

/* Generator Card */
.generator-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 4px 6px var(--shadow);
    margin-bottom: 2rem;
}

/* Password Display */
.password-display {
    margin-bottom: 1.5rem;
}

.password-output {
    width: 100%;
    padding: 1.5rem;
    font-size: 1.3rem;
    font-family: 'Courier New', monospace;
    background: var(--bg-secondary);
    border: 3px solid var(--accent);
    border-radius: 12px;
    color: var(--text-primary);
    text-align: center;
    margin-bottom: 1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    word-break: break-all;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.15);
    font-weight: 600;
    min-height: 60px;
}

.password-output:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

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

/* Buttons */
.btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s ease, color 0.3s ease, transform 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-family: inherit;
    will-change: background-color, transform;
    transform: translateZ(0);
}

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

.btn-primary:hover {
    background: var(--accent-hover);
}

.btn-secondary {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 1px solid var(--border);
}

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

.btn-copy {
    background: #10b981;
    color: white;
    flex: 1;
}

.btn-copy:hover {
    background: #059669;
}

.btn-copy.copied {
    background: #059669;
}

.btn-refresh {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 1px solid var(--border);
    padding: 0.75rem 1.5rem;
    flex: 1;
    min-height: 48px;
}

.btn-refresh:hover {
    background: var(--accent);
    color: white;
}

.btn-generate {
    flex: 1;
    min-height: 48px;
    transition: none;
}

.btn-icon {
    font-size: 1.2rem;
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }
}

/* Strength Indicator */
.strength-indicator {
    margin-bottom: 2rem;
    padding: 1rem;
    background: var(--bg-secondary);
    border-radius: 8px;
    min-height: 80px;
}

.strength-label {
    font-size: 0.9rem;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    min-height: 1.2em;
    opacity: 0.9;
}

.strength-bar {
    width: 100%;
    height: 8px;
    min-height: 8px;
    background: var(--border);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.5rem;
    position: relative;
}

.strength-fill {
    height: 100%;
    width: 0%;
    min-width: 0;
    transition: width 0.3s ease, background-color 0.3s ease;
    border-radius: 4px;
    will-change: width;
    transform: translateZ(0);
}

.strength-fill.weak {
    width: 25%;
    background: var(--strength-weak);
}

.strength-fill.medium {
    width: 50%;
    background: var(--strength-medium);
}

.strength-fill.strong {
    width: 75%;
    background: var(--strength-strong);
}

.strength-fill.very-strong {
    width: 100%;
    background: var(--strength-very-strong);
}

.strength-text {
    min-height: 1.2em;
    display: inline-block;
    font-weight: 600;
    color: var(--text-primary);
}

/* Ensure strength text has good contrast in dark mode */
[data-theme="dark"] .strength-text {
    font-weight: 700;
}

/* Options Section */
.options-section {
    margin-bottom: 2rem;
}

.password-length-group {
    margin-bottom: 1.5rem;
}

.options-accordion {
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    background: var(--bg-secondary);
}

.options-accordion-toggle {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    background: transparent;
    border: none;
    cursor: pointer;
    transition: background 0.2s ease;
}

.options-accordion-toggle:hover {
    background: var(--bg-hover);
}

.options-title {
    font-size: 1.3rem;
    font-weight: 600;
    margin: 0;
    color: var(--text-primary);
}

.accordion-icon {
    font-size: 0.9rem;
    color: var(--text-primary);
    opacity: 0.7;
    transition: transform 0.3s ease;
    will-change: transform;
    transform: translateZ(0);
}

.options-accordion-toggle[aria-expanded="true"] .accordion-icon {
    transform: rotate(180deg);
}

.options-accordion-content {
    height: 0;
    overflow: hidden;
    transition: none;
}

.options-accordion-content.expanded {
    height: auto;
}

.options-accordion-inner {
    overflow: hidden;
}

.options-accordion-inner .options-grid {
    padding: 1rem 1.5rem;
}

.options-accordion-inner .option-group {
    padding: 0 1.5rem;
}

.options-accordion-inner .option-group:first-of-type {
    padding-top: 1rem;
}

.options-accordion-inner .option-group:last-of-type {
    padding-bottom: 1rem;
}


.options-accordion-content .options-grid {
    padding-top: 1rem;
    padding-bottom: 1rem;
}

.options-accordion-content .option-group {
    padding-left: 1.5rem;
    padding-right: 1.5rem;
}


.option-group {
    margin-bottom: 1.5rem;
}

.option-label {
    display: block;
    margin-bottom: 0.5rem;
}

.label-text {
    display: block;
    font-weight: 500;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.slider-container {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.slider {
    flex: 1;
    height: 8px;
    border-radius: 4px;
    background: var(--border);
    outline: none;
    -webkit-appearance: none;
}

.slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--accent);
    cursor: pointer;
    transition: all 0.3s ease;
}

.slider::-webkit-slider-thumb:hover {
    transform: scale(1.2);
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.2);
}

.slider::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--accent);
    cursor: pointer;
    border: none;
    transition: all 0.3s ease;
}

.slider-value {
    font-weight: 600;
    color: var(--accent);
    min-width: 40px;
    text-align: center;
}

.options-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    padding: 0.75rem;
    border-radius: 8px;
    transition: background 0.3s ease;
}

.checkbox-label:hover {
    background: var(--bg-secondary);
}

.checkbox-label input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: var(--accent);
}

/* Multiple Passwords */
.multiple-section {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
}

.multiple-controls {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
    margin-bottom: 1rem;
    align-items: center;
}

.number-input {
    padding: 0.75rem 1rem;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 1rem;
    font-weight: 600;
    width: 100px;
    text-align: center;
    height: auto;
    box-sizing: border-box;
    line-height: 1.5;
}

/* Hide number input spinner */
.number-input::-webkit-outer-spin-button,
.number-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.number-input {
    -moz-appearance: textfield;
}

.passwords-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.password-item {
    padding: 1rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 8px;
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.5rem;
    min-width: 0;
    /* Allows flex item to shrink below content size */
}

.password-item-text {
    flex: 1;
    min-width: 0;
    /* Critical for text truncation in flexbox */
    word-break: break-all;
    overflow-wrap: break-word;
    overflow: visible;
}

.password-item-copy {
    background: var(--accent);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 0.25rem 1rem;
    cursor: pointer;
    font-size: 1rem;
    font-family: inherit;
    font-weight: 600;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s ease;
    white-space: nowrap;
}

.password-item-copy:hover {
    background: var(--accent-hover);
}

.password-item-copy.copied {
    background: #10b981;
}

/* SEO Content */
.content-section {
    margin: 3rem 0;
}

.seo-content {
    background: var(--bg-card);
    padding: 2rem;
    border-radius: 12px;
    border: 1px solid var(--border);
    margin-bottom: 2rem;
}

.seo-content h2 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.seo-content h3 {
    font-size: 1.4rem;
    margin-top: 1.5rem;
    margin-bottom: 1rem;
    color: var(--accent);
}

.seo-content p {
    margin-bottom: 1rem;
    color: var(--text-primary);
    opacity: 0.85;
    line-height: 1.8;
}

.seo-content ul {
    margin-left: 2rem;
    margin-bottom: 1rem;
}

.seo-content li {
    margin-bottom: 0.5rem;
    color: var(--text-primary);
    opacity: 0.85;
    line-height: 1.8;
}

/* FAQ Section */
.faq-section {
    background: var(--bg-card);
    padding: 2rem;
    border-radius: 12px;
    border: 1px solid var(--border);
}

.faq-section h2 {
    font-size: 1.8rem;
    margin-bottom: 2rem;
    color: var(--text-primary);
}

.faq-item {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border);
}

.faq-item:last-child {
    border-bottom: none;
}

.faq-question {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.faq-answer {
    color: var(--text-primary);
    opacity: 0.85;
    line-height: 1.8;
}

/* Social Sharing Section */
.sharing-section {
    margin: 3rem 0;
}

.sharing-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
}

.sharing-card h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.sharing-card p {
    color: var(--text-primary);
    opacity: 0.85;
    margin-bottom: 1.5rem;
}

.social-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: center;
}

.social-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: background-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease, color 0.3s ease, border-color 0.3s ease;
    border: none;
    cursor: pointer;
    font-family: inherit;
    font-size: 0.95rem;
    will-change: transform, background-color;
    transform: translateZ(0);
}

.social-btn.twitter {
    background: #1DA1F2;
    color: white;
}

.social-btn.twitter:hover {
    background: #0d8bd9;
    transform: translateZ(0) translateY(-2px);
    box-shadow: 0 4px 12px rgba(29, 161, 242, 0.4);
}

.social-btn.facebook {
    background: #1877F2;
    color: white;
}

.social-btn.facebook:hover {
    background: #166fe5;
    transform: translateZ(0) translateY(-2px);
    box-shadow: 0 4px 12px rgba(24, 119, 242, 0.4);
}

.social-btn.linkedin {
    background: #0A66C2;
    color: white;
}

.social-btn.linkedin:hover {
    background: #09599a;
    transform: translateZ(0) translateY(-2px);
    box-shadow: 0 4px 12px rgba(10, 102, 194, 0.4);
}

.social-btn.reddit {
    background: #FF4500;
    color: white;
}

.social-btn.reddit:hover {
    background: #e63e00;
    transform: translateZ(0) translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 69, 0, 0.4);
}

.social-btn.copy-link {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 1px solid var(--border);
}

.social-btn.copy-link:hover {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
    transform: translateZ(0) translateY(-2px);
}

/* Footer */
.footer {
    background: var(--bg-secondary);
    padding: 2rem 0;
    margin-top: 4rem;
    border-top: 1px solid var(--border);
    text-align: center;
}

.footer p {
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    opacity: 0.85;
}

.footer a {
    color: var(--accent);
    text-decoration: none;
}

.footer a:hover {
    text-decoration: underline;
}

.footer-note {
    font-size: 0.9rem;
    margin-top: 1rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .generator-card {
        padding: 1.5rem;
    }

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

    .password-actions {
        flex-direction: row;
        gap: 0.75rem;
    }

    .btn-copy {
        flex: 1;
    }

    .btn-refresh {
        padding: 0.5rem 1rem;
        flex: 1;
        min-height: 48px;
    }

    .passwords-list {
        grid-template-columns: 1fr;
    }

    .seo-content,
    .faq-section {
        padding: 1.5rem;
    }

    .header-content {
        gap: 1rem;
    }

    .header-buttons {
        gap: 0.5rem;
    }

    .menu-toggle {
        display: block !important;
    }

    .logo-img {
        height: 35px;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 1.75rem;
    }

    .generator-card {
        padding: 1rem;
    }

    .btn-generate {
        font-size: 1rem;
        padding: 0.875rem;
    }

    .social-buttons {
        flex-direction: column;
    }

    .social-btn {
        width: 100%;
        justify-content: center;
    }
}

/* Loading Animation */
@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.loading {
    display: inline-block;
    animation: spin 1s linear infinite;
}


/* Legal & Content Pages */
.legal-page,
.content-page {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 3rem;
    margin: 2rem 0;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

.legal-page h1,
.content-page h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

/* Fix deprecated API warning: explicit font-size for h1 in sections */
section h1,
.content-page section h1,
.legal-page section h1 {
    font-size: 2.5rem;
}

.last-updated {
    color: var(--text-primary);
    opacity: 0.75;
    font-size: 0.9rem;
    margin-bottom: 2rem;
    font-style: italic;
}

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

.legal-page h2,
.content-page h2 {
    font-size: 1.8rem;
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: var(--accent);
}

.legal-page h3,
.content-page h3 {
    font-size: 1.4rem;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.legal-page ul,
.content-page ul {
    margin-left: 2rem;
    margin-bottom: 1rem;
}

.legal-page li,
.content-page li {
    margin-bottom: 0.5rem;
    line-height: 1.8;
    color: var(--text-primary);
    opacity: 0.85;
}

.legal-page p,
.content-page p {
    margin-bottom: 1rem;
    line-height: 1.8;
    color: var(--text-primary);
    opacity: 0.85;
}

.legal-page code,
.content-page code {
    background: var(--bg-secondary);
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
    color: var(--accent);
}

.legal-page a,
.content-page a {
    color: var(--accent);
    text-decoration: none;
}

.legal-page a:hover,
.content-page a:hover {
    text-decoration: underline;
}

/* Contact Form */
.contact-section {
    margin: 2rem 0;
}

.contact-form-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    margin-top: 2rem;
}

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

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

.form-group label {
    font-weight: 600;
    color: var(--text-primary);
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 0.75rem;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-family: inherit;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.contact-info {
    padding: 1.5rem;
    background: var(--bg-secondary);
    border-radius: 8px;
    border: 1px solid var(--border);
}

.contact-info h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.contact-info p {
    margin-bottom: 1rem;
    color: var(--text-primary);
    opacity: 0.85;
    line-height: 1.8;
}

/* Form Success Message */
.form-success {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 2rem;
    background: linear-gradient(135deg, #10b981, #059669);
    border-radius: 12px;
    color: white;
    margin-top: 1.5rem;
    animation: slideIn 0.5s ease;
}

.success-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    font-weight: bold;
    flex-shrink: 0;
    animation: scaleIn 0.5s ease;
}

.success-content h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: white;
}

.success-content p {
    color: rgba(255, 255, 255, 0.9);
    margin: 0;
    line-height: 1.6;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes scaleIn {
    from {
        transform: scale(0);
    }

    to {
        transform: scale(1);
    }
}

/* Toast Notifications */
.toast {
    position: fixed;
    top: 20px;
    right: 20px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1rem 1.5rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    gap: 1rem;
    min-width: 300px;
    max-width: 400px;
    z-index: 10000;
    opacity: 0;
    transform: translateX(400px);
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.toast.show {
    opacity: 1;
    transform: translateX(0);
}

.toast-success {
    border-left: 4px solid #10b981;
}

.toast-error {
    border-left: 4px solid #ef4444;
}

.toast-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    font-weight: bold;
    flex-shrink: 0;
}

.toast-success .toast-icon {
    background: #10b981;
    color: white;
}

.toast-error .toast-icon {
    background: #ef4444;
    color: white;
}

.toast-message {
    flex: 1;
    color: var(--text-primary);
    font-weight: 500;
    line-height: 1.5;
}

.toast-close {
    background: transparent;
    border: none;
    color: var(--text-primary);
    opacity: 0.8;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.toast-close:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

/* Button loading state */
.btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* Responsive toast */
@media (max-width: 480px) {
    .toast {
        right: 10px;
        left: 10px;
        min-width: auto;
        max-width: none;
    }

    .form-success {
        flex-direction: column;
        text-align: center;
    }
}

/* Cookie Consent Banner */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--bg-card);
    border-top: 1px solid var(--border);
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
    z-index: 10000;
    padding: 1.5rem;
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    visibility: visible !important;
    opacity: 1 !important;
}

.cookie-banner.show {
    transform: translateY(0);
}

.cookie-banner-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
}

.cookie-banner-text {
    flex: 1;
}

.cookie-banner-text h3 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.cookie-banner-text p {
    color: var(--text-primary);
    opacity: 0.9;
    line-height: 1.6;
    margin: 0;
    font-size: 0.95rem;
}

.cookie-banner-text a {
    color: var(--accent);
    text-decoration: underline;
}

.cookie-banner-actions {
    display: flex;
    gap: 1rem;
    flex-shrink: 0;
}

.cookie-banner-actions .btn {
    white-space: nowrap;
    padding: 0.75rem 1.5rem;
}

/* Responsive cookie banner */
@media (max-width: 768px) {
    .cookie-banner-content {
        flex-direction: column;
        align-items: stretch;
        gap: 1rem;
    }

    .cookie-banner-actions {
        width: 100%;
    }

    .cookie-banner-actions .btn {
        flex: 1;
    }
}

/* Responsive for Legal/Content Pages */
@media (max-width: 768px) {

    .legal-page,
    .content-page {
        padding: 2rem 1.5rem;
    }

    .legal-page h1,
    .content-page h1 {
        font-size: 2rem;
    }

    .contact-form-container {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .nav {
        flex-direction: column;
        gap: 1rem;
        margin-top: 1rem;
    }
}

@media (max-width: 480px) {

    .legal-page,
    .content-page {
        padding: 1.5rem 1rem;
    }

    .header {
        padding: 0.75rem 0;
    }

    .header-content {
        gap: 0.5rem;
    }

    .header-buttons {
        gap: 0.25rem;
    }

    .logo-img {
        height: 30px;
    }

    .theme-toggle {
        padding: 0.4rem 0.75rem;
        font-size: 1rem;
    }

    .menu-toggle {
        padding: 0.4rem 0.6rem;
        font-size: 1.3rem;
    }

    .nav {
        font-size: 0.9rem;
    }

    .nav a {
        padding: 0.65rem 1.25rem;
    }

    .btn-refresh {
        padding: 0.4rem 0.75rem;
        flex: 1;
        min-height: 44px;
    }

    .btn-icon {
        font-size: 1rem;
    }
}