/* Custom CSS for TrueIndexium */
:root {
    --color-primary: #dc2626;
    --color-secondary: #000000;
    --color-accent: #64748b;
}

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

/* Custom button hover effects */
.btn-primary {
    background-color: var(--color-primary);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 0.25rem;
    font-weight: 500;
    transition: opacity 0.2s ease-in-out;
}

.btn-primary:hover {
    opacity: 0.9;
}

/* Form focus styles */
input:focus,
textarea:focus,
select:focus {
    outline: none;
    ring: 2px;
    ring-color: var(--color-primary);
    border-color: var(--color-primary);
}

/* Custom animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

/* Mobile menu animation */
.mobile-menu-enter {
    animation: slideDown 0.3s ease-out;
}

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

/* Cookie banner styles */
#cookie-banner {
    transition: transform 0.3s ease-in-out;
}

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

#cookie-banner.hide {
    transform: translateY(100%);
}

/* Ensure proper z-index for modals */
.modal-backdrop {
    z-index: 60;
}

.modal-content {
    z-index: 61;
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: var(--color-primary);
}

/* Print styles */
@media print {
    .no-print {
        display: none !important;
    }
}

/* 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;
}

/* Focus visible for better accessibility */
.focus-visible:focus {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

/* Custom table styles */
table {
    border-collapse: collapse;
    width: 100%;
}

table th,
table td {
    text-align: left;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #e5e7eb;
}

table th {
    background-color: #f9fafb;
    font-weight: 600;
    color: #111827;
}

/* Loading spinner */
.spinner {
    border: 2px solid #f3f4f6;
    border-top: 2px solid var(--color-primary);
    border-radius: 50%;
    width: 20px;
    height: 20px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Error and success message styles */
.message-success {
    background-color: #dcfce7;
    border: 1px solid #bbf7d0;
    color: #166534;
}

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

.message-info {
    background-color: #dbeafe;
    border: 1px solid #bfdbfe;
    color: #1e40af;
}

/* Responsive image styles */
.responsive-img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Card hover effects */
.card-hover {
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}

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

/* Custom prose styles for legal pages */
.prose h2 {
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.prose h3 {
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}

.prose p {
    margin-bottom: 1rem;
    line-height: 1.7;
}

.prose ul,
.prose ol {
    margin-bottom: 1rem;
    padding-left: 1.5rem;
}

.prose li {
    margin-bottom: 0.5rem;
}

/* Custom link styles */
.link-primary {
    color: var(--color-primary);
    text-decoration: none;
    transition: color 0.2s ease-in-out;
}

.link-primary:hover {
    color: var(--color-secondary);
    text-decoration: underline;
}

/* Utility classes */
.text-balance {
    text-wrap: balance;
}

.container-narrow {
    max-width: 48rem;
    margin-left: auto;
    margin-right: auto;
}

.container-wide {
    max-width: 80rem;
    margin-left: auto;
    margin-right: auto;
}

/* Dark mode support (if needed in future) */
@media (prefers-color-scheme: dark) {
    /* Dark mode styles can be added here if needed */
}
/* 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; }
