/* Custom CSS for PrecisionAdvisor */

/* CSS Variables */
:root {
    --color-primary: #000000;
    --color-secondary: #f59e0b;
    --color-accent: #16a34a;
}

/* Font Family Override */
body {
    font-family: 'Open Sans', sans-serif;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--color-primary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #333333;
}

/* Focus States */
button:focus,
input:focus,
textarea:focus,
select:focus {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

/* Custom Button Hover Effects */
.btn-primary {
    background-color: var(--color-primary);
    color: white;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

/* Navigation Active State */
.nav-active {
    color: var(--color-primary) !important;
    font-weight: 600;
}

/* Card Hover Effects */
.card-hover {
    transition: all 0.3s ease;
}

.card-hover:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* Smooth Scrolling */
html {
    scroll-behavior: smooth;
}

/* Custom Link Styles */
a {
    transition: color 0.2s ease;
}

/* Form Validation Styles */
.form-error {
    border-color: #ef4444;
}

.form-success {
    border-color: var(--color-accent);
}

/* Loading Animation */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

/* Mobile Menu Animation */
#mobile-menu {
    transition: all 0.3s ease;
}

/* Icon Hover Effects */
.icon-hover {
    transition: all 0.2s ease;
}

.icon-hover:hover {
    color: var(--color-secondary);
    transform: scale(1.1);
}

/* Hero Section Gradient Overlay */
.hero-overlay {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.7) 0%, rgba(0, 0, 0, 0.4) 100%);
}

/* Cookie Banner Styles */
#cookie-banner {
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(0, 0, 0, 0.1);
}

/* Animation Classes */
.fade-in {
    animation: fadeIn 0.5s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.slide-down {
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Typography */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
        line-height: 1.2;
    }
    
    .hero-subtitle {
        font-size: 1.25rem;
    }
}

/* Print Styles */
@media print {
    .no-print {
        display: none;
    }
    
    body {
        font-size: 12pt;
        line-height: 1.4;
    }
}

/* High Contrast Mode Support */
@media (prefers-contrast: high) {
    :root {
        --color-primary: #000000;
        --color-secondary: #ff6600;
        --color-accent: #008800;
    }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* Dark Mode Support (for future implementation) */
@media (prefers-color-scheme: dark) {
    /* Dark mode styles would go here if needed */
}

/* Custom Table Styles */
table {
    border-collapse: collapse;
}

table th,
table td {
    border: 1px solid #e5e7eb;
}

/* Form Enhancement */
.form-group {
    position: relative;
}

.form-label {
    font-weight: 500;
    margin-bottom: 0.5rem;
    display: block;
}

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

/* Skip Link */
.skip-link {
    position: absolute;
    top: -40px;
    left: 6px;
    background: var(--color-primary);
    color: white;
    padding: 8px;
    text-decoration: none;
    z-index: 1000;
}

.skip-link:focus {
    top: 6px;
}

/* Custom Checkbox Styles */
input[type="checkbox"] {
    accent-color: var(--color-primary);
}

/* Footer Enhancements */
footer a:hover {
    text-decoration: underline;
}

/* Button Loading State */
.btn-loading {
    position: relative;
    color: transparent;
}

.btn-loading::after {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    top: 50%;
    left: 50%;
    margin-left: -8px;
    margin-top: -8px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Section Spacing Utilities */
.section-padding {
    padding-top: 4rem;
    padding-bottom: 4rem;
}

@media (min-width: 768px) {
    .section-padding {
        padding-top: 6rem;
        padding-bottom: 6rem;
    }
}

/* Custom Grid Layouts */
.grid-auto-fit {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

/* Image Optimization */
img {
    max-width: 100%;
    height: auto;
}

/* Focus Visible Support */
.focus-visible:focus {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}
/* Cookie banner visibility — independent of Tailwind */
#cookie-banner.hidden, #cookie-consent-banner.hidden { display: none !important; }
#cookie-banner:not(.hidden), #cookie-consent-banner:not(.hidden) { display: block !important; }
#cookie-modal.hidden { display: none !important; }
