/* ========================================
   Turza – WOW Effects & Microinteractions
   Premium experience layer
   ======================================== */

/* ---- No-JS Fallback ----
   Sections are visible by default.
   JS adds .wow-loaded to body to enable animations.
   ---------------------------------------- */

/* ---- Typography Refinement ---- */
body {
    font-size: 1.0625rem; /* 17px base */
}

.section-title {
    line-height: 1.2;
}

/* ---- Section Reveal on Scroll ---- */
.wow-loaded .reveal-section {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal-section.revealed {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

/* ---- Hero Animation Enhancement ---- */
.wow-loaded .hero .hero-badge {
    animation: wowFadeUp 0.7s cubic-bezier(0.22, 1, 0.36, 1) 0.2s both;
}

.wow-loaded .hero .hero-title {
    animation: wowFadeUp 0.85s cubic-bezier(0.22, 1, 0.36, 1) 0.35s both;
}

.wow-loaded .hero .hero-subtitle {
    animation: wowFadeUp 0.7s cubic-bezier(0.22, 1, 0.36, 1) 0.5s both;
}

.wow-loaded .hero .hero-desc {
    animation: wowFadeUp 0.7s cubic-bezier(0.22, 1, 0.36, 1) 0.6s both;
}

.wow-loaded .hero .hero-buttons {
    animation: wowFadeUp 0.7s cubic-bezier(0.22, 1, 0.36, 1) 0.75s both;
}

.wow-loaded .hero .hero-image {
    animation: wowSlideIn 1s cubic-bezier(0.22, 1, 0.36, 1) 0.45s both;
}

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

@keyframes wowSlideIn {
    from {
        opacity: 0;
        transform: translateX(40px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateX(0) scale(1);
    }
}

/* Hero subtitle (new element) */
.hero-subtitle {
    font-family: var(--font-display);
    font-size: 1.25rem;
    color: var(--color-secondary);
    font-weight: 400;
    font-style: italic;
    margin-bottom: 1rem;
    letter-spacing: 0.02em;
}

/* Hero image parallax – GPU accelerated */
.hero-image-main {
    will-change: transform;
}

/* ---- Journey Section (Signature Moment) ---- */
.journey {
    padding: 7rem 2rem;
    background: var(--color-cream);
    overflow: hidden;
}

.journey-container {
    max-width: 1100px;
    margin: 0 auto;
}

.journey .section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto;
}

.journey .section-desc {
    color: var(--color-text-light);
    font-size: 1.1rem;
}

.journey-timeline {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-top: 4rem;
    position: relative;
}

/* Connecting line between step icons */
.journey-timeline::before {
    content: '';
    position: absolute;
    top: 65px;
    left: calc(16.67% + 25px);
    right: calc(16.67% + 25px);
    height: 2px;
    background: linear-gradient(90deg,
        var(--color-secondary),
        var(--color-secondary-light),
        var(--color-secondary));
    opacity: 0;
    transition: opacity 1s ease 0.6s;
}

.journey-timeline.revealed::before {
    opacity: 0.35;
}

.journey-step {
    text-align: center;
    position: relative;
}

/* Animated step appearance */
.wow-loaded .journey-step {
    opacity: 0;
    transform: translateY(25px);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.journey-step.revealed {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

.journey-step:nth-child(1) { transition-delay: 0.1s; }
.journey-step:nth-child(2) { transition-delay: 0.3s; }
.journey-step:nth-child(3) { transition-delay: 0.5s; }

.journey-step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    background: var(--color-secondary);
    color: white;
    border-radius: 50%;
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 1rem;
    font-family: var(--font-body);
}

.journey-icon {
    width: 100px;
    height: 100px;
    margin: 0 auto 1.5rem;
    background: white;
    border: 2px solid var(--color-secondary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 1;
    transition: all 0.4s cubic-bezier(0.22, 1, 0.36, 1);
    box-shadow: 0 4px 15px rgba(26, 61, 46, 0.06);
}

.journey-step:hover .journey-icon {
    background: var(--color-primary);
    border-color: var(--color-primary);
    transform: scale(1.08);
    box-shadow: 0 8px 25px rgba(26, 61, 46, 0.15);
}

.journey-step:hover .journey-icon svg {
    stroke: white;
}

.journey-icon svg {
    width: 42px;
    height: 42px;
    fill: none;
    stroke: var(--color-primary);
    stroke-width: 1.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition: stroke 0.4s ease;
}

.journey-step h3 {
    font-family: var(--font-display);
    font-size: 1.4rem;
    color: var(--color-primary);
    margin-bottom: 0.75rem;
    line-height: 1.25;
}

.journey-step p {
    color: var(--color-text-light);
    font-size: 0.95rem;
    line-height: 1.7;
    max-width: 280px;
    margin: 0 auto;
}

/* ---- Subpage Header Animations ---- */
.wow-loaded .page-header h1 {
    animation: wowFadeUp 0.7s cubic-bezier(0.22, 1, 0.36, 1) 0.1s both;
}

.wow-loaded .page-header p {
    animation: wowFadeUp 0.7s cubic-bezier(0.22, 1, 0.36, 1) 0.25s both;
}

.wow-loaded .page-header-content {
    animation: wowFadeUp 0.8s cubic-bezier(0.22, 1, 0.36, 1) 0.1s both;
}

.wow-loaded .page-header-image {
    animation: wowSlideIn 0.9s cubic-bezier(0.22, 1, 0.36, 1) 0.3s both;
}

.wow-loaded .breadcrumb {
    animation: wowFadeUp 0.6s cubic-bezier(0.22, 1, 0.36, 1) 0.05s both;
}

/* ---- Stagger Reveal (card grids) ---- */
.wow-loaded .reveal-stagger > * {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal-stagger.revealed > * {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

.reveal-stagger.revealed > *:nth-child(1) { transition-delay: 0.05s; }
.reveal-stagger.revealed > *:nth-child(2) { transition-delay: 0.12s; }
.reveal-stagger.revealed > *:nth-child(3) { transition-delay: 0.19s; }
.reveal-stagger.revealed > *:nth-child(4) { transition-delay: 0.26s; }
.reveal-stagger.revealed > *:nth-child(5) { transition-delay: 0.33s; }
.reveal-stagger.revealed > *:nth-child(6) { transition-delay: 0.40s; }
.reveal-stagger.revealed > *:nth-child(7) { transition-delay: 0.47s; }
.reveal-stagger.revealed > *:nth-child(8) { transition-delay: 0.54s; }

/* ---- Enhanced Product Card Microinteractions ---- */
.product-card {
    transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1),
                box-shadow 0.45s cubic-bezier(0.22, 1, 0.36, 1) !important;
}

.product-card:hover {
    transform: translateY(-8px) !important;
    box-shadow: 0 16px 48px rgba(26, 61, 46, 0.14) !important;
}

.product-image img {
    transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1) !important;
}

.product-card:hover .product-image img {
    transform: scale(1.03) !important;
}

/* ---- Enhanced Button Microinteractions ---- */
.btn:active {
    transform: translateY(1px) scale(0.97) !important;
    transition-duration: 0.1s !important;
}

.btn:focus-visible {
    outline: 3px solid var(--color-secondary);
    outline-offset: 3px;
}

.btn-primary:focus-visible {
    outline-color: var(--color-secondary-light);
}

/* ---- General Card Hover Enhancement ---- */
.feature-card,
.award-card,
.value-card,
.service-card {
    transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1),
                box-shadow 0.45s cubic-bezier(0.22, 1, 0.36, 1),
                background 0.4s ease !important;
}

/* ---- Stat Counter ---- */
.stat-number[data-target],
.count-up[data-target] {
    font-variant-numeric: tabular-nums;
}

/* ---- Reduced Motion ---- */
@media (prefers-reduced-motion: reduce) {
    .wow-loaded .reveal-section {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .wow-loaded .journey-step {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .wow-loaded .hero .hero-badge,
    .wow-loaded .hero .hero-title,
    .wow-loaded .hero .hero-subtitle,
    .wow-loaded .hero .hero-desc,
    .wow-loaded .hero .hero-buttons,
    .wow-loaded .hero .hero-image,
    .wow-loaded .page-header h1,
    .wow-loaded .page-header p,
    .wow-loaded .page-header-content,
    .wow-loaded .page-header-image,
    .wow-loaded .breadcrumb {
        animation: none;
        opacity: 1;
        transform: none;
    }

    .wow-loaded .reveal-stagger > * {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .journey-timeline::before {
        opacity: 0.35;
        transition: none;
    }

    .hero-image-main {
        transform: none !important;
    }

    .product-card,
    .feature-card,
    .award-card,
    .value-card,
    .service-card,
    .btn {
        transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease !important;
    }

    .product-card:hover,
    .feature-card:hover,
    .award-card:hover,
    .value-card:hover,
    .service-card:hover {
        transform: none !important;
    }
}

/* ---- Responsive ---- */
@media (max-width: 768px) {
    .journey {
        padding: 5rem 1.5rem;
    }

    .journey-timeline {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }

    .journey-timeline::before {
        display: none;
    }

    .journey-icon {
        width: 80px;
        height: 80px;
    }

    .journey-icon svg {
        width: 36px;
        height: 36px;
    }

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