/**
 * SABER - Custom Styles (Novacolor-inspired Redesign)
 * ===================================================
 * Architectural, Minimalist, Luxury.
 */

/* ============================================================================
   CSS CUSTOM PROPERTIES (Design Tokens)
   ============================================================================ */

:root {
    /* Palette Saber - Refined (Luxury Gold & Black) */
    --saber-dark: #111111;
    --saber-gold: #c5a572;
    --saber-gold-dark: #b08d55;
    /* Legacy mapping for safety, but mapped to Gold/Dark */
    --saber-blue: var(--saber-gold);

    /* Architectural Palette */
    --arch-white: #ffffff;
    --arch-gray-light: #f9f9f9;
    --arch-gray-med: #e5e5e5;
    --arch-gray-dark: #333333;
    --arch-black: #111111;

    /* Typography */
    --font-sans: 'Inter', system-ui, -apple-system, sans-serif;
    --font-display: 'Montserrat', system-ui, -apple-system, sans-serif;

    /* Spacing */
    --header-height: 90px;
    /* Slightly taller for grandeur */

    /* Transitions */
    --transition-fast: 200ms cubic-bezier(0.16, 1, 0.3, 1);
    --transition-normal: 400ms cubic-bezier(0.16, 1, 0.3, 1);
    --transition-slow: 700ms cubic-bezier(0.16, 1, 0.3, 1);
}

/* ============================================================================
   BASE STYLES
   ============================================================================ */

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-sans);
    /* background-color rimosso - gestito inline in ogni pagina */
    color: var(--arch-black);
    line-height: 1.6;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-display);
    font-weight: 700;
    letter-spacing: -0.02em;
}

/* Focus visible */
:focus-visible {
    outline: 2px solid var(--saber-blue);
    outline-offset: 4px;
}

/* ============================================================================
   TYPOGRAPHY UTILITIES
   ============================================================================ */

.text-display {
    font-family: var(--font-display);
}

.text-arch-title {
    font-family: var(--font-display);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 600;
}

/* ============================================================================
   BUTTON STYLES (Minimalist - Square)
   ============================================================================ */

.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2rem;
    background-color: var(--saber-blue);
    color: white;
    font-family: var(--font-display);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-size: 0.875rem;
    border: none;
    border-radius: 0;
    /* Sharp design */
    transition: all var(--transition-fast);
}

.btn-primary:hover {
    background-color: var(--saber-dark);
    transform: translateY(-2px);
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.9rem 1.9rem;
    background-color: transparent;
    color: var(--saber-blue);
    font-family: var(--font-display);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-size: 0.875rem;
    border: 2px solid var(--saber-blue);
    border-radius: 0;
    /* Sharp design */
    transition: all var(--transition-fast);
}

.btn-secondary:hover {
    background-color: var(--saber-blue);
    color: white;
}

/* ============================================================================
   CARD HOVER EFFECTS (Editorial - Zoom)
   ============================================================================ */

.hover-card {
    position: relative;
    overflow: hidden;
    background-color: white;
    transition: box-shadow var(--transition-normal);
}

.hover-card img {
    transition: transform var(--transition-slow);
    will-change: transform;
}

.hover-card:hover img {
    transform: scale(1.05);
    /* Subtle zoom */
}

.hover-card:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
    /* Soft diffuse shadow */
    z-index: 10;
}

/* Overlay for text readability on cards if needed */
.card-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.7) 0%, transparent 60%);
    opacity: 0.8;
    transition: opacity var(--transition-normal);
}

.hover-card:hover .card-overlay {
    opacity: 0.9;
}

/* ============================================================================
   HEADER STYLES
   ============================================================================ */

/* .header-sticky removed or updated to avoid conflict with index.html specific logic */
.header-sticky {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    transition: all var(--transition-normal);
}

/* Force transparent background when explicit class is present (used in index.html via JS logic) */
#main-header.bg-transparent {
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.5) 0%, rgba(0, 0, 0, 0) 100%) !important;
    box-shadow: none !important;
    backdrop-filter: none !important;
    border-bottom: none !important;
}

/* ============================================================================
   HERO VIDEO STYLES
   ============================================================================ */

.hero-video-container {
    position: relative;
    overflow: hidden;
}

.hero-video {
    width: 100%;
    height: 100vh;
    /* More dramatic height */
    object-fit: cover;
    margin: 0;
    clip-path: none;
    /* Removed the chop for full bleed elegance */
}

@media (max-width: 768px) {
    .hero-video {
        height: auto !important;
        min-height: auto !important;
        object-fit: contain !important;
    }
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.3);
    /* Darken slightly for white text contrast */
}

/* Title Styling in Hero */
.hero-title {
    font-family: var(--font-display);
    font-weight: 800;
    letter-spacing: -0.03em;
    text-transform: uppercase;
}

/* ============================================================================
   FOOTER STYLES
   ============================================================================ */

.footer-link {
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    transition: color var(--transition-fast);
}

.footer-link:hover {
    color: white;
}

/* ============================================================================
   UTILITY ANIMATIONS
   ============================================================================ */

@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

.animate-spin {
    animation: spin 1s linear infinite;
}

/* ============================================================================
   COOKIE BANNER
   ============================================================================ */

.cookie-banner {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(12px);
    border-top: 1px solid #eee;
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.05);
}

@media (min-width: 768px) {
    #cookie-banner {
        padding-right: 140px !important;
    }
}

/* ============================================================================
   MEDIA QUERIES
   ============================================================================ */

@media print {

    header,
    footer,
    .cookie-banner {
        display: none !important;
    }
}

@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
}

/* ============================================================================
   SCROLL ANIMATIONS (Fade Up)
   ============================================================================ */
.reveal-on-scroll {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 1s cubic-bezier(0.16, 1, 0.3, 1), transform 1s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: opacity, transform;
}

.reveal-on-scroll.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.delay-100 {
    transition-delay: 0.1s;
}

.delay-200 {
    transition-delay: 0.2s;
}

.delay-300 {
    transition-delay: 0.3s;
}

.delay-500 {
    transition-delay: 0.5s;
}