/**
 * Year in Travel Recap - Main Styles
 *
 * Spotify Wrapped-style full-screen carousel experience
 * Travel adventure theme with Safaroto branding
 */

/* ============================================
   CSS Custom Properties
   ============================================ */
:root {
    --yr-primary: #24B8F4;
    --yr-primary-dark: #1a8fc2;
    --yr-accent: #FFE02B;
    --yr-accent-dark: #d4ba00;
    --yr-bg-dark: #0c1e2b;
    --yr-bg-darker: #081620;
    --yr-text-light: #ffffff;
    --yr-text-muted: rgba(255, 255, 255, 0.8);
    --yr-text-subtle: rgba(255, 255, 255, 0.65);
    --yr-overlay: rgba(12, 30, 43, 0.75);
    --yr-card-bg: rgba(255, 255, 255, 0.1);
    --yr-card-border: rgba(255, 255, 255, 0.15);
    --yr-transition: 0.3s ease;
    --yr-transition-slow: 0.6s ease;
}

/* ============================================
   Container & Base Layout
   ============================================ */
.year-recap-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: var(--yr-bg-dark);
    z-index: 99999;
    overflow: hidden;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
}

.year-recap-container * {
    box-sizing: border-box;
}

/* ============================================
   Progress Bar
   ============================================ */
.year-recap-progress {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.2);
    z-index: 100;
}

.year-recap-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--yr-primary), var(--yr-accent));
    width: 10%;
    transition: width var(--yr-transition);
}

/* ============================================
   Navigation Controls
   ============================================ */
.year-recap-nav {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    transform: translateY(-50%);
    display: flex;
    justify-content: space-between;
    padding: 0 20px;
    pointer-events: none;
    z-index: 100;
}

.year-recap-nav-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--yr-card-bg);
    border: 1px solid var(--yr-card-border);
    color: var(--yr-text-light);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: auto;
    transition: all var(--yr-transition);
    backdrop-filter: blur(10px);
}

.year-recap-nav-btn:hover:not(:disabled) {
    background: var(--yr-primary);
    border-color: var(--yr-primary);
    transform: scale(1.1);
}

.year-recap-nav-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.year-recap-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--yr-card-bg);
    border: 1px solid var(--yr-card-border);
    color: var(--yr-text-light);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100;
    transition: all var(--yr-transition);
    backdrop-filter: blur(10px);
}

.year-recap-close:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

/* ============================================
   Slides Container
   ============================================ */
.year-recap-slides {
    width: 100%;
    height: 100%;
    display: flex;
    transition: transform var(--yr-transition-slow);
}

.year-recap-slide {
    flex: 0 0 100%;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 40px;
    position: relative;
    overflow: hidden;
}

/* Slide backgrounds */
.year-recap-slide::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--yr-overlay);
    z-index: 1;
}

.year-recap-slide-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    filter: blur(5px) brightness(0.4);
    transform: scale(1.1);
    z-index: 0;
}

.year-recap-slide-content {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 600px;
    text-align: center;
}

/* ============================================
   Slide Indicators
   ============================================ */
.year-recap-indicators {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 100;
}

.year-recap-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    border: none;
    cursor: pointer;
    transition: all var(--yr-transition);
    padding: 0;
}

.year-recap-indicator:hover {
    background: rgba(255, 255, 255, 0.5);
}

.year-recap-indicator.active {
    background: var(--yr-accent);
    width: 24px;
    border-radius: 4px;
}

/* ============================================
   Typography
   ============================================ */
.year-recap-title,
.year-recap-title.fusion-responsive-typography-calculated {
    font-size: 3rem;
    font-weight: 800;
    color: var(--yr-text-light);
    margin: 0 0 20px;
    line-height: 1.1;
}

.year-recap-title .highlight {
    color: var(--yr-accent);
}

.year-recap-subtitle {
    font-size: 1.25rem;
    color: var(--yr-text-muted);
    margin: 0 0 30px;
    font-weight: 400;
}

.year-recap-number {
    font-size: 8rem;
    font-weight: 900;
    color: var(--yr-text-light);
    line-height: 1;
    margin: 20px 0;
    background: linear-gradient(135deg, var(--yr-text-light) 0%, var(--yr-accent) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.year-recap-number.counting {
    animation: numberPulse 0.5s ease infinite;
}

.year-recap-label {
    font-size: 1.5rem;
    color: var(--yr-text-muted);
    text-transform: uppercase;
    letter-spacing: 3px;
    font-weight: 600;
}

/* ============================================
   Animations
   ============================================ */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes numberPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

@keyframes stampIn {
    0% {
        opacity: 0;
        transform: scale(2) rotate(-10deg);
    }
    50% {
        opacity: 1;
        transform: scale(0.9) rotate(2deg);
    }
    100% {
        opacity: 1;
        transform: scale(1) rotate(0deg);
    }
}

@keyframes planeFloat {
    0%, 100% { transform: translateY(0) rotate(-5deg); }
    50% { transform: translateY(-10px) rotate(5deg); }
}

@keyframes drawRoute {
    to {
        stroke-dashoffset: 0;
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Slide entrance animations */
.year-recap-slide.active .year-recap-title {
    animation: fadeInUp 0.6s ease forwards;
}

.year-recap-slide.active .year-recap-subtitle {
    animation: fadeInUp 0.6s ease 0.1s forwards;
    opacity: 0;
}

.year-recap-slide.active .year-recap-number {
    animation: scaleIn 0.8s ease 0.2s forwards;
    opacity: 0;
}

.year-recap-slide.active .year-recap-label {
    animation: fadeInUp 0.6s ease 0.4s forwards;
    opacity: 0;
}

/* ============================================
   Flag Grid (Countries slide)
   ============================================ */
.year-recap-flags {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
    margin: 30px 0;
    max-width: 500px;
}

.year-recap-flag {
    width: 60px;
    height: 40px;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    opacity: 0;
    transform: scale(2) rotate(-10deg);
}

.year-recap-flag img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.year-recap-slide.active .year-recap-flag {
    animation: stampIn 0.4s ease forwards;
}

/* Stagger flag animations */
.year-recap-slide.active .year-recap-flag:nth-child(1) { animation-delay: 0.3s; }
.year-recap-slide.active .year-recap-flag:nth-child(2) { animation-delay: 0.4s; }
.year-recap-slide.active .year-recap-flag:nth-child(3) { animation-delay: 0.5s; }
.year-recap-slide.active .year-recap-flag:nth-child(4) { animation-delay: 0.6s; }
.year-recap-slide.active .year-recap-flag:nth-child(5) { animation-delay: 0.7s; }
.year-recap-slide.active .year-recap-flag:nth-child(6) { animation-delay: 0.8s; }
.year-recap-slide.active .year-recap-flag:nth-child(7) { animation-delay: 0.9s; }
.year-recap-slide.active .year-recap-flag:nth-child(8) { animation-delay: 1.0s; }
.year-recap-slide.active .year-recap-flag:nth-child(9) { animation-delay: 1.1s; }
.year-recap-slide.active .year-recap-flag:nth-child(10) { animation-delay: 1.2s; }
.year-recap-slide.active .year-recap-flag:nth-child(11) { animation-delay: 1.3s; }
.year-recap-slide.active .year-recap-flag:nth-child(12) { animation-delay: 1.4s; }
.year-recap-slide.active .year-recap-flag:nth-child(13) { animation-delay: 1.5s; }
.year-recap-slide.active .year-recap-flag:nth-child(14) { animation-delay: 1.6s; }
.year-recap-slide.active .year-recap-flag:nth-child(15) { animation-delay: 1.7s; }
.year-recap-slide.active .year-recap-flag:nth-child(16) { animation-delay: 1.8s; }
.year-recap-slide.active .year-recap-flag:nth-child(17) { animation-delay: 1.9s; }
.year-recap-slide.active .year-recap-flag:nth-child(18) { animation-delay: 2.0s; }
.year-recap-slide.active .year-recap-flag:nth-child(19) { animation-delay: 2.1s; }
.year-recap-slide.active .year-recap-flag:nth-child(20) { animation-delay: 2.2s; }
.year-recap-slide.active .year-recap-flag:nth-child(21) { animation-delay: 2.3s; }
.year-recap-slide.active .year-recap-flag:nth-child(22) { animation-delay: 2.4s; }
.year-recap-slide.active .year-recap-flag:nth-child(23) { animation-delay: 2.5s; }
.year-recap-slide.active .year-recap-flag:nth-child(24) { animation-delay: 2.6s; }
.year-recap-slide.active .year-recap-flag:nth-child(n+25) { animation-delay: 2.7s; }

/* ============================================
   Avatar Grid (Companions slide)
   ============================================ */
.year-recap-avatars {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
    margin: 30px 0;
    max-width: 400px;
}

.year-recap-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    overflow: hidden;
    border: 3px solid var(--yr-card-border);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    opacity: 0;
    transform: scale(0);
}

.year-recap-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.year-recap-slide.active .year-recap-avatar {
    animation: scaleIn 0.4s ease forwards;
}

/* Stagger avatar animations */
.year-recap-slide.active .year-recap-avatar:nth-child(1) { animation-delay: 0.3s; }
.year-recap-slide.active .year-recap-avatar:nth-child(2) { animation-delay: 0.4s; }
.year-recap-slide.active .year-recap-avatar:nth-child(3) { animation-delay: 0.5s; }
.year-recap-slide.active .year-recap-avatar:nth-child(4) { animation-delay: 0.6s; }
.year-recap-slide.active .year-recap-avatar:nth-child(5) { animation-delay: 0.7s; }
.year-recap-slide.active .year-recap-avatar:nth-child(6) { animation-delay: 0.8s; }
.year-recap-slide.active .year-recap-avatar:nth-child(7) { animation-delay: 0.9s; }
.year-recap-slide.active .year-recap-avatar:nth-child(8) { animation-delay: 1.0s; }
.year-recap-slide.active .year-recap-avatar:nth-child(9) { animation-delay: 1.1s; }
.year-recap-slide.active .year-recap-avatar:nth-child(10) { animation-delay: 1.2s; }
.year-recap-slide.active .year-recap-avatar:nth-child(11) { animation-delay: 1.3s; }
.year-recap-slide.active .year-recap-avatar:nth-child(12) { animation-delay: 1.4s; }
.year-recap-slide.active .year-recap-avatar:nth-child(n+13) { animation-delay: 1.5s; }

/* ============================================
   Top Travel Buddy Card
   ============================================ */
.year-recap-top-buddy {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    margin-top: 30px;
    padding: 15px 20px;
    background: var(--yr-card-bg);
    border-radius: 12px;
    border: 1px solid var(--yr-card-border);
    backdrop-filter: blur(10px);
}

.top-buddy-label {
    color: var(--yr-text-muted);
    font-size: 0.85rem;
    margin: 0;
    text-align: center;
}

.top-buddy-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

.top-buddy-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--yr-accent);
    flex-shrink: 0;
}

.top-buddy-info {
    text-align: left;
}

.top-buddy-name {
    color: var(--yr-accent);
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0 !important;
}

.top-buddy-trips {
    color: var(--yr-text-muted);
    font-weight: 400;
    font-size: 0.85rem;
    margin: 2px 0 0;
}

/* ============================================
   Companions Slide - Compact Flexbox Layout
   ============================================ */
.year-recap-slide-companions {
    padding: 20px 20px 70px 20px;
}

/* Flexbox container for proper layout */
.year-recap-companions-content {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    max-height: var(--yr-safe-height);
    max-height: var(--yr-safe-height-dvh);
    overflow: hidden;
    gap: 12px;
}

/* Compact header section */
.year-recap-companions-header {
    flex-shrink: 0;
    text-align: center;
}

.year-recap-companions-header .year-recap-subtitle {
    margin-bottom: 8px;
    font-size: 1.1rem;
}

/* Stats row - trips and members side by side */
.year-recap-companions-stats {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
}

.companions-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.companions-stat-number {
    font-size: 3.5rem;
    font-weight: 900;
    line-height: 1;
    background: linear-gradient(135deg, var(--yr-text-light) 0%, var(--yr-accent) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.companions-stat-label {
    font-size: 0.85rem;
    color: var(--yr-text-muted);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-weight: 600;
    margin-top: 4px;
}

.companions-stat-divider {
    font-size: 1rem;
    color: var(--yr-text-subtle);
    font-weight: 400;
}

/* Scrollable avatars wrapper */
.year-recap-avatars-wrapper {
    flex: 1 1 auto;
    min-height: 0;
    max-height: 100%;
    overflow: hidden;
    width: 100%;
    display: flex;
    justify-content: center;
}

.year-recap-avatars-wrapper.avatars-many {
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--yr-card-border) transparent;
}

.year-recap-avatars-wrapper::-webkit-scrollbar {
    width: 4px;
}

.year-recap-avatars-wrapper::-webkit-scrollbar-track {
    background: transparent;
}

.year-recap-avatars-wrapper::-webkit-scrollbar-thumb {
    background: var(--yr-card-border);
    border-radius: 2px;
}

/* Avatars grid inside wrapper */
.year-recap-slide-companions .year-recap-avatars {
    margin: 0 auto;
    gap: 10px;
    max-width: 380px;
    align-content: flex-start;
}

.year-recap-slide-companions .year-recap-avatar {
    width: 48px;
    height: 48px;
}

/* Compact avatars when many members */
.year-recap-avatars.avatars-compact {
    gap: 6px;
    max-width: 340px;
}

.year-recap-avatars.avatars-compact .year-recap-avatar {
    width: 38px;
    height: 38px;
    border-width: 2px;
}

/* Top buddy card - always visible at bottom */
.year-recap-slide-companions .year-recap-top-buddy {
    flex-shrink: 0;
    margin: 0 auto;
    padding: 12px 18px;
    max-width: 300px;
    gap: 8px;
}

.year-recap-slide-companions .top-buddy-avatar {
    width: 44px;
    height: 44px;
}

.year-recap-slide-companions .top-buddy-label {
    font-size: 0.8rem;
}

.year-recap-slide-companions .top-buddy-name {
    font-size: 1rem;
}

/* Responsive: Tablet */
@media (max-width: 768px) {
    .year-recap-slide-companions {
        padding: 60px 15px 80px;
    }

    .year-recap-companions-content {
        gap: 10px;
    }

    .companions-stat-number {
        font-size: 3rem;
    }

    .companions-stat-label {
        font-size: 0.75rem;
        letter-spacing: 1px;
    }

    .year-recap-slide-companions .year-recap-avatars {
        max-width: 320px;
        gap: 8px;
    }

    .year-recap-slide-companions .year-recap-avatar {
        width: 42px;
        height: 42px;
    }

    .year-recap-avatars.avatars-compact {
        max-width: 300px;
        gap: 5px;
    }

    .year-recap-avatars.avatars-compact .year-recap-avatar {
        width: 34px;
        height: 34px;
    }
}

/* Responsive: Mobile */
@media (max-width: 480px) {
    .year-recap-companions-stats {
        gap: 12px;
    }

    .companions-stat-number {
        font-size: 2.5rem;
    }

    .companions-stat-label {
        font-size: 0.7rem;
    }

    .year-recap-slide-companions .year-recap-avatars {
        max-width: 280px;
        gap: 6px;
    }

    .year-recap-slide-companions .year-recap-avatar {
        width: 36px;
        height: 36px;
        border-width: 2px;
    }

    .year-recap-avatars.avatars-compact {
        max-width: 260px;
        gap: 4px;
    }

    .year-recap-avatars.avatars-compact .year-recap-avatar {
        width: 30px;
        height: 30px;
    }

    .year-recap-slide-companions .year-recap-top-buddy {
        padding: 8px 12px;
        max-width: 280px;
    }

    .year-recap-slide-companions .top-buddy-avatar {
        width: 38px;
        height: 38px;
    }

    .year-recap-slide-companions .top-buddy-name {
        font-size: 0.9rem;
    }
}

/* Desktop: Companions slide */
@media (min-width: 1024px) {
    .companions-stat-number {
        font-size: 4.5rem;
    }

    .companions-stat-label {
        font-size: 0.9rem;
        letter-spacing: 2px;
    }

    .year-recap-slide-companions .year-recap-avatars {
        max-width: 450px;
        gap: 12px;
    }

    .year-recap-slide-companions .year-recap-avatar {
        width: 56px;
        height: 56px;
    }

    .year-recap-avatars.avatars-compact {
        max-width: 400px;
        gap: 8px;
    }

    .year-recap-avatars.avatars-compact .year-recap-avatar {
        width: 44px;
        height: 44px;
    }

    .year-recap-slide-companions .year-recap-top-buddy {
        max-width: 340px;
        padding: 12px 20px;
    }

    .year-recap-slide-companions .top-buddy-avatar {
        width: 50px;
        height: 50px;
    }
}

/* Extra Large Desktop */
@media (min-width: 1440px) {
    .companions-stat-number {
        font-size: 5.5rem;
    }

    .companions-stat-label {
        font-size: 1rem;
    }

    .year-recap-slide-companions .year-recap-avatars {
        max-width: 520px;
        gap: 14px;
    }

    .year-recap-slide-companions .year-recap-avatar {
        width: 64px;
        height: 64px;
    }

    .year-recap-avatars.avatars-compact {
        max-width: 480px;
        gap: 10px;
    }

    .year-recap-avatars.avatars-compact .year-recap-avatar {
        width: 52px;
        height: 52px;
    }
}

/* ============================================
   Trip Thumbnails Grid - Dynamic Sizing
   ============================================ */
.year-recap-thumbnails {
    display: grid;
    gap: 8px;
    margin: 30px auto;
    justify-content: center;
}

/* Grid size variations based on trip count */
/* XS: 1-4 trips - 2 columns, large thumbnails */
.year-recap-thumbnails.grid-size-xs {
    grid-template-columns: repeat(2, 110px);
    gap: 12px;
}

/* SM: 5-9 trips - 3 columns, medium thumbnails */
.year-recap-thumbnails.grid-size-sm {
    grid-template-columns: repeat(3, 90px);
    gap: 10px;
}

/* MD: 10-16 trips - 4 columns, small thumbnails */
.year-recap-thumbnails.grid-size-md {
    grid-template-columns: repeat(4, 70px);
    gap: 8px;
}

/* LG: 17-25 trips - 5 columns, smaller thumbnails */
.year-recap-thumbnails.grid-size-lg {
    grid-template-columns: repeat(5, 56px);
    gap: 6px;
}

/* XL: 26-36 trips - 6 columns, tiny thumbnails */
.year-recap-thumbnails.grid-size-xl {
    grid-template-columns: repeat(6, 46px);
    gap: 5px;
}

/* XXL: 37+ trips - 7 columns, minimum size */
.year-recap-thumbnails.grid-size-xxl {
    grid-template-columns: repeat(7, 40px);
    gap: 4px;
}

.year-recap-thumbnail {
    aspect-ratio: 1;
    border-radius: 8px;
    overflow: hidden;
    opacity: 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

/* Smaller border radius for smaller thumbnails */
.grid-size-lg .year-recap-thumbnail,
.grid-size-xl .year-recap-thumbnail,
.grid-size-xxl .year-recap-thumbnail {
    border-radius: 6px;
}

.year-recap-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--yr-transition);
}

.year-recap-thumbnail:hover img {
    transform: scale(1.1);
}

.year-recap-slide.active .year-recap-thumbnail {
    animation: fadeIn 0.4s ease forwards;
}

/* ============================================
   Map Slide
   ============================================ */
.year-recap-map-container {
    width: 100%;
    max-width: 800px;
    height: 400px;
    border-radius: 20px;
    overflow: hidden;
    margin: 20px 0;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}

.year-recap-map {
    width: 100%;
    height: 100%;
}

/* ============================================
   Summary Slide
   ============================================ */
.year-recap-summary-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin: 30px auto;
    max-width: 500px;
}

.year-recap-summary-item {
    background: var(--yr-card-bg);
    border: 1px solid var(--yr-card-border);
    border-radius: 16px;
    padding: 25px 20px;
    text-align: center;
    backdrop-filter: blur(10px);
    opacity: 0;
    transform: translateX(50px);
}

/* When slide is active, ensure items become visible */
.year-recap-slide.active .year-recap-summary-item {
    opacity: 1;
    transform: translateX(0);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.year-recap-slide.active .year-recap-summary-item:nth-child(1) { transition-delay: 0.2s; }
.year-recap-slide.active .year-recap-summary-item:nth-child(2) { transition-delay: 0.3s; }
.year-recap-slide.active .year-recap-summary-item:nth-child(3) { transition-delay: 0.4s; }
.year-recap-slide.active .year-recap-summary-item:nth-child(4) { transition-delay: 0.5s; }

.year-recap-summary-item .number {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--yr-accent);
    margin-bottom: 5px;
}

.year-recap-summary-item .label {
    font-size: 0.875rem;
    color: var(--yr-text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* ============================================
   Share/Download Buttons
   ============================================ */
.year-recap-actions {
    display: flex;
    gap: 15px;
    margin-top: 30px;
    flex-wrap: wrap;
    justify-content: center;
}

.year-recap-btn {
    padding: 14px 28px;
    border-radius: 30px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--yr-transition);
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.year-recap-btn-primary {
    background: var(--yr-accent);
    color: var(--yr-bg-dark);
    border: none;
}

.year-recap-btn-primary:hover {
    background: var(--yr-accent-dark);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(255, 224, 43, 0.3);
}

.year-recap-btn-secondary {
    background: transparent;
    color: var(--yr-text-light);
    border: 2px solid var(--yr-card-border);
}

.year-recap-btn-secondary:hover {
    background: var(--yr-card-bg);
    border-color: var(--yr-text-light);
}

/* ============================================
   Opening Slide Specific
   ============================================ */
.year-recap-opening-icon {
    width: 80px;
    height: 80px;
    margin-bottom: 30px;
    animation: planeFloat 3s ease-in-out infinite;
}

.year-recap-year-badge {
    display: inline-block;
    background: var(--yr-accent);
    color: var(--yr-bg-dark);
    padding: 8px 20px;
    border-radius: 20px;
    font-weight: 700;
    font-size: 1.25rem;
    margin-bottom: 20px;
}

/* ============================================
   First/Last Trip Comparison
   ============================================ */
.year-recap-comparison {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    max-width: 600px;
    margin: 30px 0;
}

.year-recap-trip-card {
    background: var(--yr-card-bg);
    border: 1px solid var(--yr-card-border);
    border-radius: 16px;
    overflow: hidden;
    backdrop-filter: blur(10px);
}

.year-recap-trip-card-image {
    height: 120px;
    background-size: cover;
    background-position: center;
}

.year-recap-trip-card-content {
    padding: 15px;
}

.year-recap-trip-card-label {
    font-size: 0.75rem;
    color: var(--yr-accent);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 5px;
}

.year-recap-trip-card-title {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--yr-text-light);
    margin-bottom: 5px;
}

.year-recap-trip-card-date {
    font-size: 0.875rem;
    color: var(--yr-text-muted);
}

/* ============================================
   No Data State
   ============================================ */
.year-recap-no-data,
.year-recap-login-required {
    text-align: center;
    padding: 60px 20px;
    max-width: 500px;
    margin: 0 auto;
}

.year-recap-no-data h2,
.year-recap-login-required h2 {
    color: #333;
    margin-bottom: 15px;
}

.year-recap-no-data p,
.year-recap-login-required p {
    color: #666;
    margin-bottom: 20px;
}

.btn-add-trip {
    display: inline-block;
    padding: 12px 24px;
    background: var(--yr-primary);
    color: white;
    text-decoration: none;
    border-radius: 25px;
    font-weight: 600;
    transition: all var(--yr-transition);
}

.btn-add-trip:hover {
    background: var(--yr-primary-dark);
    transform: translateY(-2px);
}

/* ============================================
   Responsive Design
   ============================================ */
@media (max-width: 768px) {
    .year-recap-slide {
        padding: 80px 20px 100px;
    }

    .year-recap-title {
        font-size: 2rem;
    }

    .year-recap-number {
        font-size: 5rem;
    }

    .year-recap-label {
        font-size: 1rem;
        letter-spacing: 2px;
    }

    .year-recap-nav {
        display: none;
    }

    .year-recap-summary-grid {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }

    .year-recap-summary-item {
        padding: 15px;
    }

    .year-recap-summary-item .number {
        font-size: 1.75rem;
    }

    .year-recap-comparison {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .year-recap-map-container {
        height: 300px;
        border-radius: 12px;
    }

    .year-recap-actions {
        flex-direction: column;
        align-items: center;
    }

    .year-recap-btn {
        width: 100%;
        max-width: 280px;
        justify-content: center;
    }

    .year-recap-indicators {
        bottom: 20px;
    }

    .year-recap-close {
        top: 15px;
        right: 15px;
        width: 40px;
        height: 40px;
    }

    /* Thumbnails grid - tablet adjustments */
    .year-recap-thumbnails.grid-size-xs {
        grid-template-columns: repeat(2, 90px);
    }
    .year-recap-thumbnails.grid-size-sm {
        grid-template-columns: repeat(3, 75px);
    }
    .year-recap-thumbnails.grid-size-md {
        grid-template-columns: repeat(4, 60px);
    }
    .year-recap-thumbnails.grid-size-lg {
        grid-template-columns: repeat(5, 50px);
    }
    .year-recap-thumbnails.grid-size-xl {
        grid-template-columns: repeat(6, 42px);
    }
    .year-recap-thumbnails.grid-size-xxl {
        grid-template-columns: repeat(7, 36px);
    }
}

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

    .year-recap-number {
        font-size: 4rem;
    }

    .year-recap-flags {
        gap: 10px;
    }

    .year-recap-flag {
        width: 50px;
        height: 33px;
    }

    .year-recap-avatars {
        gap: 10px;
    }

    .year-recap-avatar {
        width: 50px;
        height: 50px;
    }

    /* Thumbnails grid - mobile adjustments (reduce columns) */
    .year-recap-thumbnails.grid-size-xs {
        grid-template-columns: repeat(2, 80px);
        gap: 8px;
    }
    .year-recap-thumbnails.grid-size-sm {
        grid-template-columns: repeat(3, 65px);
        gap: 6px;
    }
    .year-recap-thumbnails.grid-size-md {
        grid-template-columns: repeat(4, 52px);
        gap: 5px;
    }
    .year-recap-thumbnails.grid-size-lg {
        grid-template-columns: repeat(5, 44px);
        gap: 4px;
    }
    .year-recap-thumbnails.grid-size-xl {
        grid-template-columns: repeat(6, 38px);
        gap: 4px;
    }
    .year-recap-thumbnails.grid-size-xxl {
        grid-template-columns: repeat(6, 38px);
        gap: 3px;
    }

    .year-recap-thumbnail {
        border-radius: 5px;
    }
}

/* ============================================
   Touch/Swipe Support
   ============================================ */
.year-recap-container.touch-active .year-recap-slides {
    transition: none;
}

/* ============================================
   Prefers Reduced Motion
   ============================================ */
@media (prefers-reduced-motion: reduce) {
    .year-recap-slide.active .year-recap-title,
    .year-recap-slide.active .year-recap-subtitle,
    .year-recap-slide.active .year-recap-number,
    .year-recap-slide.active .year-recap-label,
    .year-recap-slide.active .year-recap-flag,
    .year-recap-slide.active .year-recap-avatar,
    .year-recap-slide.active .year-recap-thumbnail,
    .year-recap-slide.active .year-recap-summary-item {
        animation: none;
        transition: none;
        opacity: 1;
        transform: none;
    }

    .year-recap-opening-icon {
        animation: none;
    }

    .year-recap-slides {
        transition: none;
    }
}

/* ============================================
   Fullscreen Mode
   ============================================ */

/* Fullscreen mode - covers everything including admin bar */
.year-recap-container.fullscreen-mode {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    height: 100dvh !important; /* Dynamic viewport height for mobile */
    z-index: 999999 !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* Body class to hide site elements when fullscreen is active */
body.year-recap-open,
body.recap-fullscreen-active {
    overflow: hidden !important;
}

body.year-recap-open #wpadminbar,
body.year-recap-open .admin-bar-fix,
body.year-recap-open header,
body.year-recap-open .site-header,
body.year-recap-open .elementor-location-header,
body.year-recap-open nav.primary-navigation,
body.year-recap-open .nav-primary,
body.year-recap-open .nav-panel,
body.year-recap-open .mobile-nav,
body.year-recap-open footer,
body.year-recap-open .site-footer,
body.recap-fullscreen-active #wpadminbar,
body.recap-fullscreen-active .admin-bar-fix,
body.recap-fullscreen-active header,
body.recap-fullscreen-active .site-header,
body.recap-fullscreen-active .elementor-location-header,
body.recap-fullscreen-active nav.primary-navigation,
body.recap-fullscreen-active .nav-primary,
body.recap-fullscreen-active .nav-panel,
body.recap-fullscreen-active .mobile-nav,
body.recap-fullscreen-active footer,
body.recap-fullscreen-active .site-footer {
    display: none !important;
}

/* Ensure recap container sits above WordPress admin bar */
body.admin-bar .year-recap-container.fullscreen-mode {
    top: 0 !important;
}

/* Close button styling for fullscreen mode */
.year-recap-container.fullscreen-mode .year-recap-close {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 101;
    width: 48px;
    height: 48px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.year-recap-container.fullscreen-mode .year-recap-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* Mobile adjustments for fullscreen */
@media (max-width: 768px) {
    .year-recap-container.fullscreen-mode .year-recap-close {
        top: 12px;
        right: 12px;
        width: 40px;
        height: 40px;
    }
}

/* ============================================
   Year Recap Quick Button (Calendar/Itinerary)
   ============================================ */

/* Button that appears next to year headers */
.year-recap-quick-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    margin-left: 8px;
    padding: 0;
    background: rgba(36, 184, 244, 0.2);
    border: 1px solid rgba(36, 184, 244, 0.4);
    border-radius: 50%;
    color: #24B8F4;
    cursor: pointer;
    transition: all 0.2s ease;
    vertical-align: middle;
    opacity: 0.7;
}

.year-recap-quick-btn:hover {
    background: #24B8F4;
    border-color: #24B8F4;
    color: #fff;
    opacity: 1;
    transform: scale(1.1);
}

.year-recap-quick-btn i {
    font-size: 14px;
}

/* Timeline year header enhancement */
.timeline-year-header.recap-enhanced {
    display: flex;
    align-items: center;
    gap: 4px;
}

.timeline-year-header .year-recap-quick-btn {
    position: relative;
    z-index: 10;
}

/* Dark theme variant */
.dark-theme .year-recap-quick-btn,
[data-theme="dark"] .year-recap-quick-btn {
    background: rgba(36, 184, 244, 0.3);
    border-color: rgba(36, 184, 244, 0.5);
}

.dark-theme .year-recap-quick-btn:hover,
[data-theme="dark"] .year-recap-quick-btn:hover {
    background: #24B8F4;
}

/* Mobile adjustments */
@media (max-width: 768px) {
    .year-recap-quick-btn {
        width: 24px;
        height: 24px;
        margin-left: 6px;
    }

    .year-recap-quick-btn i {
        font-size: 12px;
    }
}

/* ============================================
   3D Globe with Timeline Slide
   ============================================ */

/* Layout container */
.year-recap-globe-layout {
    max-width: 1100px !important;
    width: 100%;
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 40px 20px;
}

.year-recap-globe-header {
    text-align: center;
    margin-bottom: 20px;
    flex-shrink: 0;
}

.year-recap-globe-content {
    display: flex;
    gap: 24px;
    flex: 1;
    min-height: 0;
    align-items: stretch;
}

.year-recap-globe-footer {
    text-align: center;
    margin-top: 16px;
    flex-shrink: 0;
}

.year-recap-globe-footer .globe-stat {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--yr-text-subtle);
    font-size: 0.9rem;
}

.year-recap-globe-footer .globe-stat svg {
    opacity: 0.7;
}

/* ============================================
   Photo Timeline (Left Panel)
   ============================================ */
.year-recap-timeline {
    width: 220px;
    flex-shrink: 0;
    position: relative;
    overflow: hidden;
}

.year-recap-timeline-scroll {
    height: 100%;
    overflow-y: auto;
    padding-right: 8px;
    scrollbar-width: thin;
    scrollbar-color: var(--yr-card-border) transparent;
}

.year-recap-timeline-scroll::-webkit-scrollbar {
    width: 4px;
}

.year-recap-timeline-scroll::-webkit-scrollbar-track {
    background: transparent;
}

.year-recap-timeline-scroll::-webkit-scrollbar-thumb {
    background: var(--yr-card-border);
    border-radius: 2px;
}

.year-recap-timeline-item {
    display: flex;
    gap: 12px;
    margin-bottom: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.year-recap-timeline-item:last-child {
    margin-bottom: 0;
}

/* Timeline connector (dot + line) */
.timeline-item-connector {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 16px;
    flex-shrink: 0;
    padding-top: 20px;
}

.timeline-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--yr-card-border);
    border: 2px solid var(--yr-bg-dark);
    box-shadow: 0 0 0 2px var(--yr-card-border);
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.year-recap-timeline-item.active .timeline-dot,
.year-recap-timeline-item:hover .timeline-dot {
    background: var(--yr-accent);
    box-shadow: 0 0 0 2px var(--yr-accent), 0 0 12px var(--yr-accent);
}

.timeline-line {
    width: 2px;
    flex: 1;
    background: linear-gradient(to bottom, var(--yr-card-border), transparent);
    margin-top: 4px;
    min-height: 20px;
}

.year-recap-timeline-item.active .timeline-line {
    background: linear-gradient(to bottom, var(--yr-accent), var(--yr-card-border));
}

/* Timeline card */
.timeline-item-card {
    flex: 1;
    background: var(--yr-card-bg);
    border: 1px solid var(--yr-card-border);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.year-recap-timeline-item.active .timeline-item-card,
.year-recap-timeline-item:hover .timeline-item-card {
    border-color: var(--yr-accent);
    box-shadow: 0 4px 20px rgba(255, 224, 43, 0.15);
    transform: translateX(4px);
}

.timeline-item-photo {
    height: 80px;
    background-size: cover;
    background-position: center;
    position: relative;
}

.timeline-item-photo::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 40px;
    background: linear-gradient(to top, rgba(12, 30, 43, 0.8), transparent);
}

.timeline-item-photo-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--yr-bg-darker);
    color: var(--yr-text-subtle);
}

.timeline-item-info {
    padding: 10px 12px;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.timeline-item-location {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--yr-text-light);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.timeline-item-date {
    font-size: 0.75rem;
    color: var(--yr-text-subtle);
}

/* ============================================
   3D Globe Container
   ============================================ */
.year-recap-globe-wrapper {
    flex: 1;
    min-width: 0;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(ellipse at center, rgba(36, 184, 244, 0.05) 0%, transparent 70%);
    border-radius: 20px;
    overflow: hidden;
}

.year-recap-globe {
    width: 100%;
    height: 100%;
    min-height: 350px;
}

.year-recap-globe canvas {
    outline: none !important;
}

/* Globe loading state */
.year-recap-globe-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    color: var(--yr-text-subtle);
    font-size: 0.9rem;
    z-index: 5;
    transition: opacity 0.3s ease;
}

.year-recap-globe-wrapper.loaded .year-recap-globe-loading {
    opacity: 0;
    pointer-events: none;
}

.globe-loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--yr-card-border);
    border-top-color: var(--yr-primary);
    border-radius: 50%;
    animation: globeSpin 1s linear infinite;
}

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

/* Fallback map container */
.year-recap-map-fallback {
    width: 100%;
    height: 100%;
}

.year-recap-map-fallback .year-recap-map {
    width: 100%;
    height: 100%;
    min-height: 300px;
    border-radius: 12px;
}

/* ============================================
   Globe Animation Classes
   ============================================ */

/* Pulsing marker effect for active destination */
@keyframes globePulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.5);
        opacity: 0.5;
    }
}

/* Arc drawing animation */
@keyframes arcDraw {
    from {
        stroke-dashoffset: 1000;
    }
    to {
        stroke-dashoffset: 0;
    }
}

/* ============================================
   Globe Slide - Responsive
   ============================================ */
@media (max-width: 900px) {
    .year-recap-globe-content {
        flex-direction: column;
    }

    .year-recap-timeline {
        width: 100%;
        max-height: 140px;
        order: 2;
    }

    .year-recap-timeline-scroll {
        display: flex;
        flex-direction: row;
        gap: 12px;
        overflow-x: auto;
        overflow-y: hidden;
        padding-bottom: 8px;
        scroll-snap-type: x mandatory;
    }

    .year-recap-timeline-item {
        flex-direction: column;
        margin-bottom: 0;
        min-width: 140px;
        scroll-snap-align: start;
    }

    .timeline-item-connector {
        display: none;
    }

    .timeline-item-card {
        width: 100%;
    }

    .timeline-item-photo {
        height: 60px;
    }

    .year-recap-globe-wrapper {
        order: 1;
        min-height: 280px;
        flex: none;
        height: 50vh;
        max-height: 400px;
    }
}

@media (max-width: 600px) {
    .year-recap-globe-layout {
        padding: 30px 15px;
    }

    .year-recap-globe-header .year-recap-title {
        font-size: 1.5rem !important;
    }

    .year-recap-timeline {
        max-height: 120px;
    }

    .year-recap-timeline-item {
        min-width: 120px;
    }

    .timeline-item-photo {
        height: 50px;
    }

    .timeline-item-info {
        padding: 8px 10px;
    }

    .timeline-item-location {
        font-size: 0.8rem;
    }

    .timeline-item-date {
        font-size: 0.7rem;
    }

    .year-recap-globe-wrapper {
        height: 45vh;
        min-height: 250px;
    }
}

/* ============================================
   Safe Content Area - Calculated Heights
   ============================================ */
/*
 * Fixed UI elements take up:
 * - Progress bar: 4px at top
 * - Indicators: ~50px from bottom (30px bottom + 10px height + 10px breathing room)
 * - Close button: 20px from top, 48px tall
 *
 * Safe content area: calc(100% - 4px - 50px) = calc(100% - 54px)
 * We use CSS custom properties for consistent calculation
 */
:root {
    --yr-safe-top: 4px;
    --yr-safe-bottom: 60px; /* indicators bottom(30-40px) + height(10px) + buffer(10-20px) */
    --yr-safe-height: calc(100vh - var(--yr-safe-top) - var(--yr-safe-bottom));
    --yr-safe-height-dvh: calc(100dvh - var(--yr-safe-top) - var(--yr-safe-bottom));
}

/* ============================================
   Combined Countries Slide (Map + Flags)
   ============================================ */

.year-recap-slide-countries-combined {
    padding: 20px 20px 70px 20px; /* Reduced top, increased bottom for indicators */
}

.year-recap-countries-combined-content {
    max-width: 1000px !important;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    height: auto;
    max-height: var(--yr-safe-height);
    max-height: var(--yr-safe-height-dvh);
    overflow: hidden;
}

.year-recap-countries-header {
    text-align: center;
    flex-shrink: 0;
}

.year-recap-countries-header .year-recap-subtitle {
    margin-bottom: 8px;
    font-size: 1.1rem;
}

.year-recap-countries-header .year-recap-title {
    font-size: 2rem;
    margin-bottom: 0;
}

.year-recap-countries-header .highlight {
    font-size: 2.5rem;
    font-weight: 900;
}

/* Map container for combined slide */
.year-recap-countries-map-container {
    width: 100%;
    max-width: 850px;
    height: 320px;
    border-radius: 16px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.05);
    position: relative;
    flex-shrink: 0;
}

.year-recap-countries-map-container svg {
    width: 100%;
    height: 100%;
}

/* Compact flag grid for combined slide */
.year-recap-flags-compact {
    gap: 8px;
    max-width: 700px;
    margin: 10px 0 0 0;
    flex-shrink: 1;
    min-height: 0; /* Allow shrinking */
    overflow-y: auto;
    overflow-x: hidden;
    max-height: 120px; /* Limit height to prevent overflow into indicators */
    padding: 4px;
    scrollbar-width: thin;
    scrollbar-color: var(--yr-card-border) transparent;
}

.year-recap-flags-compact::-webkit-scrollbar {
    width: 4px;
}

.year-recap-flags-compact::-webkit-scrollbar-track {
    background: transparent;
}

.year-recap-flags-compact::-webkit-scrollbar-thumb {
    background: var(--yr-card-border);
    border-radius: 2px;
}

.year-recap-flags-compact .year-recap-flag {
    width: 42px;
    height: 28px;
    border-radius: 4px;
    flex-shrink: 0;
}

/* Responsive: Tablet */
@media (max-width: 768px) {
    .year-recap-slide-countries-combined {
        padding: 60px 15px 80px;
    }

    .year-recap-countries-combined-content {
        gap: 12px;
    }

    .year-recap-countries-header .year-recap-title {
        font-size: 1.5rem;
    }

    .year-recap-countries-header .highlight {
        font-size: 2rem;
    }

    .year-recap-countries-map-container {
        height: 250px;
        border-radius: 12px;
    }

    .year-recap-flags-compact {
        gap: 8px;
        max-width: 100%;
    }

    .year-recap-flags-compact .year-recap-flag {
        width: 42px;
        height: 28px;
    }
}

/* Responsive: Mobile */
@media (max-width: 480px) {
    .year-recap-countries-header .year-recap-subtitle {
        font-size: 0.95rem;
    }

    .year-recap-countries-header .year-recap-title {
        font-size: 1.25rem;
    }

    .year-recap-countries-header .highlight {
        font-size: 1.75rem;
    }

    .year-recap-countries-map-container {
        height: 200px;
    }

    .year-recap-flags-compact {
        gap: 6px;
    }

    .year-recap-flags-compact .year-recap-flag {
        width: 36px;
        height: 24px;
        border-radius: 3px;
    }
}

/* Desktop: Larger screens */
@media (min-width: 1024px) {
    .year-recap-countries-combined-content {
        gap: 20px;
    }

    .year-recap-countries-header .year-recap-title {
        font-size: 2.25rem;
    }

    .year-recap-countries-header .highlight {
        font-size: 3rem;
    }

    .year-recap-countries-map-container {
        height: 380px;
        max-width: 900px;
    }

    .year-recap-flags-compact {
        gap: 12px;
        max-width: 800px;
    }

    .year-recap-flags-compact .year-recap-flag {
        width: 56px;
        height: 37px;
        border-radius: 5px;
    }
}

/* Extra Large Desktop */
@media (min-width: 1440px) {
    .year-recap-countries-map-container {
        height: 420px;
        max-width: 950px;
    }

    .year-recap-flags-compact .year-recap-flag {
        width: 64px;
        height: 43px;
    }
}

/* ============================================
   Combined Cities Slide (Map + Pills)
   ============================================ */

.year-recap-slide-cities-combined {
    padding: 20px 20px 70px 20px; /* Reduced top, increased bottom for indicators */
}

.year-recap-cities-combined-content {
    max-width: 1000px !important;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    height: auto;
    max-height: var(--yr-safe-height);
    max-height: var(--yr-safe-height-dvh);
    overflow: hidden;
}

.year-recap-cities-header {
    text-align: center;
    flex-shrink: 0;
}

.year-recap-cities-header .year-recap-subtitle {
    margin-bottom: 8px;
    font-size: 1.1rem;
}

.year-recap-cities-header .year-recap-title {
    font-size: 2rem;
    margin-bottom: 0;
}

.year-recap-cities-header .highlight {
    font-size: 2.5rem;
    font-weight: 900;
}

/* Map container for combined cities slide */
.year-recap-cities-map-container {
    width: 100%;
    max-width: 850px;
    height: 320px;
    border-radius: 16px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.05);
    position: relative;
    flex-shrink: 0;
}

.year-recap-cities-map-container svg {
    width: 100%;
    height: 100%;
}

/* City pills grid */
.year-recap-city-pills {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-content: flex-start;
    gap: 10px;
    max-width: 600px;
    margin: 10px 0 0 0;
    min-height: 0;
    flex: 1 1 auto; /* Grow to fill available space */
    overflow: hidden; /* Hidden during loading */
    position: relative;
    scrollbar-width: thin;
    scrollbar-color: var(--yr-card-border) transparent;
}

/* After loading complete, allow manual scrolling */
.year-recap-city-pills.pills-loaded {
    overflow-y: auto;
}

.year-recap-city-pills::-webkit-scrollbar {
    width: 4px;
}

.year-recap-city-pills::-webkit-scrollbar-track {
    background: transparent;
}

.year-recap-city-pills::-webkit-scrollbar-thumb {
    background: var(--yr-card-border);
    border-radius: 2px;
}

.year-recap-city-pill {
    background: var(--yr-card-bg);
    border: 1px solid var(--yr-card-border);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.9rem;
    color: var(--yr-text-light);
    backdrop-filter: blur(10px);
    opacity: 0;
    transform: translateY(10px);
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

/* Pills become visible when they have the 'visible' class */
.year-recap-city-pill.visible {
    opacity: 1;
    transform: translateY(0);
}

.year-recap-city-pill .city-pill-flag {
    width: 16px;
    height: 12px;
    border-radius: 2px;
    object-fit: cover;
}

.year-recap-cities-more {
    margin-top: 10px;
    color: var(--yr-text-subtle);
    font-size: 0.9rem;
}

/* Responsive: Tablet */
@media (max-width: 768px) {
    .year-recap-slide-cities-combined {
        padding: 60px 15px 80px;
    }

    .year-recap-cities-combined-content {
        gap: 12px;
    }

    .year-recap-cities-header .year-recap-title {
        font-size: 1.5rem;
    }

    .year-recap-cities-header .highlight {
        font-size: 2rem;
    }

    .year-recap-cities-map-container {
        height: 250px;
        border-radius: 12px;
    }

    .year-recap-city-pills {
        gap: 8px;
        max-width: 100%;
    }

    .year-recap-city-pill {
        padding: 6px 12px;
        font-size: 0.85rem;
    }
}

/* Responsive: Mobile */
@media (max-width: 480px) {
    .year-recap-cities-header .year-recap-subtitle {
        font-size: 0.95rem;
    }

    .year-recap-cities-header .year-recap-title {
        font-size: 1.25rem;
    }

    .year-recap-cities-header .highlight {
        font-size: 1.75rem;
    }

    .year-recap-cities-map-container {
        height: 200px;
    }

    .year-recap-city-pills {
        gap: 6px;
    }

    .year-recap-city-pill {
        padding: 5px 10px;
        font-size: 0.8rem;
        border-radius: 15px;
    }

    .year-recap-city-pill .city-pill-flag {
        width: 14px;
        height: 10px;
    }
}

/* Desktop: Larger screens */
@media (min-width: 1024px) {
    .year-recap-cities-combined-content {
        gap: 20px;
    }

    .year-recap-cities-header .year-recap-title {
        font-size: 2.25rem;
    }

    .year-recap-cities-header .highlight {
        font-size: 3rem;
    }

    .year-recap-cities-map-container {
        height: 380px;
        max-width: 900px;
    }

    .year-recap-city-pills {
        gap: 12px;
        max-width: 700px;
    }

    .year-recap-city-pill {
        padding: 10px 18px;
        font-size: 0.95rem;
    }
}

/* Extra Large Desktop */
@media (min-width: 1440px) {
    .year-recap-cities-map-container {
        height: 420px;
        max-width: 950px;
    }

    .year-recap-city-pill {
        padding: 12px 20px;
        font-size: 1rem;
    }
}

/* ============================================
   D3 Visualization Slides
   ============================================ */

/* Scratch Map Container (standalone - kept for backwards compatibility) */
.year-recap-scratch-map-container {
    width: 100%;
    max-width: 900px;
    height: 400px;
    margin: 20px auto;
    border-radius: 16px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.05);
    position: relative;
}

.year-recap-scratch-map-container svg {
    width: 100%;
    height: 100%;
}

/* Bar Chart Container (Top Countries/Cities) */
.year-recap-bar-chart-container {
    width: 100%;
    max-width: 550px;
    margin: 20px auto;
    padding: 10px 0;
}

.year-recap-bar-chart-container svg {
    overflow: visible;
}

/* Chart slide content adjustments */
.year-recap-chart-slide-content {
    max-width: 700px !important;
}

/* Responsive adjustments for visualization slides */
@media (max-width: 768px) {
    .year-recap-scratch-map-container {
        height: 300px;
        border-radius: 12px;
    }

    .year-recap-bar-chart-container {
        max-width: 100%;
        padding: 10px 15px;
    }

    .year-recap-chart-slide-content {
        max-width: 100% !important;
        padding-left: 10px;
        padding-right: 10px;
    }
}

@media (max-width: 480px) {
    .year-recap-scratch-map-container {
        height: 250px;
    }

    .year-recap-bar-chart-container {
        padding: 5px 10px;
    }
}

/* ============================================
   Desktop Enhancements - Large Screens
   ============================================ */

/* Desktop: 1024px+ */
@media (min-width: 1024px) {
    /* Increase slide content area for desktop */
    .year-recap-slide-content {
        max-width: 800px;
    }

    /* Larger typography for impact */
    .year-recap-number {
        font-size: 10rem;
    }

    .year-recap-label {
        font-size: 1.75rem;
        letter-spacing: 4px;
    }

    .year-recap-subtitle {
        font-size: 1.5rem;
    }

    /* Larger thumbnails grid for desktop */
    .year-recap-thumbnails.grid-size-xs {
        grid-template-columns: repeat(2, 140px);
        gap: 16px;
    }

    .year-recap-thumbnails.grid-size-sm {
        grid-template-columns: repeat(3, 115px);
        gap: 14px;
    }

    .year-recap-thumbnails.grid-size-md {
        grid-template-columns: repeat(4, 95px);
        gap: 12px;
    }

    .year-recap-thumbnails.grid-size-lg {
        grid-template-columns: repeat(5, 80px);
        gap: 10px;
    }

    .year-recap-thumbnails.grid-size-xl {
        grid-template-columns: repeat(6, 68px);
        gap: 8px;
    }

    .year-recap-thumbnails.grid-size-xxl {
        grid-template-columns: repeat(7, 58px);
        gap: 6px;
    }

    .year-recap-thumbnail {
        border-radius: 10px;
    }

    /* Larger flags for countries slide */
    .year-recap-flags {
        gap: 20px;
        max-width: 650px;
    }

    .year-recap-flag {
        width: 80px;
        height: 53px;
        border-radius: 8px;
    }

    /* Larger avatars for companions slide */
    .year-recap-avatars {
        gap: 20px;
        max-width: 550px;
    }

    .year-recap-avatar {
        width: 80px;
        height: 80px;
        border-width: 4px;
    }

    /* Summary grid enhancements */
    .year-recap-summary-grid {
        max-width: 600px;
        gap: 24px;
    }

    .year-recap-summary-item {
        padding: 30px 25px;
    }

    .year-recap-summary-item .number {
        font-size: 3rem;
    }

    .year-recap-summary-item .label {
        font-size: 1rem;
    }

    /* Trip comparison cards */
    .year-recap-comparison {
        max-width: 700px;
        gap: 40px;
    }

    .year-recap-trip-card-image {
        height: 160px;
    }

    .year-recap-trip-card-content {
        padding: 20px;
    }

    .year-recap-trip-card-title {
        font-size: 1.25rem;
    }

    /* Map container */
    .year-recap-map-container {
        max-width: 900px;
        height: 450px;
    }

    /* Navigation buttons */
    .year-recap-nav-btn {
        width: 60px;
        height: 60px;
    }

    .year-recap-nav {
        padding: 0 40px;
    }

    /* Top buddy card */
    .year-recap-top-buddy {
        padding: 20px 28px;
        gap: 20px;
    }

    .top-buddy-avatar {
        width: 60px;
        height: 60px;
    }

    .top-buddy-name {
        font-size: 1.25rem;
    }
}

/* Extra Large Desktop: 1440px+ */
@media (min-width: 1440px) {
    /* Even larger content area */
    .year-recap-slide-content {
        max-width: 950px;
    }

    /* More impactful number */
    .year-recap-number {
        font-size: 12rem;
    }

    .year-recap-label {
        font-size: 2rem;
        letter-spacing: 5px;
    }

    .year-recap-subtitle {
        font-size: 1.75rem;
    }

    .year-recap-title,
    .year-recap-title.fusion-responsive-typography-calculated {
        font-size: 3.5rem;
    }

    /* Even larger thumbnails for big screens */
    .year-recap-thumbnails.grid-size-xs {
        grid-template-columns: repeat(2, 170px);
        gap: 20px;
    }

    .year-recap-thumbnails.grid-size-sm {
        grid-template-columns: repeat(3, 140px);
        gap: 18px;
    }

    .year-recap-thumbnails.grid-size-md {
        grid-template-columns: repeat(4, 115px);
        gap: 14px;
    }

    .year-recap-thumbnails.grid-size-lg {
        grid-template-columns: repeat(5, 95px);
        gap: 12px;
    }

    .year-recap-thumbnails.grid-size-xl {
        grid-template-columns: repeat(6, 80px);
        gap: 10px;
    }

    .year-recap-thumbnails.grid-size-xxl {
        grid-template-columns: repeat(7, 70px);
        gap: 8px;
    }

    /* Larger flags */
    .year-recap-flags {
        gap: 24px;
        max-width: 800px;
    }

    .year-recap-flag {
        width: 100px;
        height: 67px;
        border-radius: 10px;
    }

    /* Larger avatars */
    .year-recap-avatars {
        gap: 24px;
        max-width: 650px;
    }

    .year-recap-avatar {
        width: 100px;
        height: 100px;
    }

    /* Summary grid */
    .year-recap-summary-grid {
        max-width: 700px;
        gap: 30px;
    }

    .year-recap-summary-item {
        padding: 35px 30px;
        border-radius: 20px;
    }

    .year-recap-summary-item .number {
        font-size: 3.5rem;
    }

    /* Comparison cards */
    .year-recap-comparison {
        max-width: 850px;
        gap: 50px;
    }

    .year-recap-trip-card {
        border-radius: 20px;
    }

    .year-recap-trip-card-image {
        height: 180px;
    }

    /* Map */
    .year-recap-map-container {
        max-width: 1000px;
        height: 500px;
        border-radius: 24px;
    }

    /* Globe layout */
    .year-recap-globe-layout {
        max-width: 1300px !important;
    }

    .year-recap-timeline {
        width: 280px;
    }

    .timeline-item-photo {
        height: 100px;
    }

    /* Navigation */
    .year-recap-nav {
        padding: 0 60px;
    }

    .year-recap-nav-btn {
        width: 70px;
        height: 70px;
    }

    /* Close button */
    .year-recap-close {
        width: 52px;
        height: 52px;
        top: 30px;
        right: 30px;
    }

    /* Indicators with more spacing */
    .year-recap-indicators {
        bottom: 40px;
        gap: 10px;
    }

    .year-recap-indicator {
        width: 10px;
        height: 10px;
    }

    .year-recap-indicator.active {
        width: 32px;
    }
}

/* ============================================
   Short Viewport Adjustments (Limited Height)
   ============================================ */

/* When vertical space is limited (e.g., laptop screens, dev tools open) */
@media (max-height: 750px) {
    .year-recap-slide {
        padding: 40px 30px 70px;
    }

    .year-recap-slide-summary .year-recap-slide-content {
        gap: 8px;
    }

    /* Reduce avatar size */
    .year-recap-slide-summary .year-recap-user-thumbnail img {
        width: 60px !important;
        height: 60px !important;
    }

    /* Compact summary grid */
    .year-recap-summary-grid {
        margin: 15px auto;
        gap: 12px;
    }

    .year-recap-summary-item {
        padding: 15px 12px;
    }

    .year-recap-summary-item .number {
        font-size: 2rem;
    }

    /* Reduce action button margins */
    .year-recap-actions {
        margin-top: 15px;
    }

    .year-recap-btn {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
}

/* Very short viewports */
@media (max-height: 650px) {
    .year-recap-slide {
        padding: 30px 20px 60px;
    }

    .year-recap-summary-grid {
        margin: 10px auto;
        gap: 8px;
    }

    .year-recap-summary-item {
        padding: 12px 10px;
    }

    .year-recap-summary-item .number {
        font-size: 1.75rem;
    }

    .year-recap-summary-item .label {
        font-size: 0.75rem;
    }

    .year-recap-actions {
        margin-top: 10px;
        gap: 10px;
    }

    .year-recap-btn {
        padding: 8px 16px;
        font-size: 0.85rem;
    }
}

/* Desktop with limited height - override large desktop styles */
@media (min-width: 1024px) and (max-height: 800px) {
    .year-recap-slide {
        padding: 40px 40px 70px;
    }

    .year-recap-slide-summary .year-recap-user-thumbnail img {
        width: 60px !important;
        height: 60px !important;
        margin-bottom: 8px !important;
    }

    .year-recap-slide-summary .year-recap-title {
        font-size: 1.75rem !important;
        margin-bottom: 8px !important;
    }

    .year-recap-slide-summary .year-recap-subtitle {
        font-size: 1rem !important;
        margin-bottom: 12px !important;
    }

    .year-recap-summary-grid {
        margin: 15px auto;
        gap: 15px;
        max-width: 450px;
    }

    .year-recap-summary-item {
        padding: 18px 15px;
    }

    .year-recap-summary-item .number {
        font-size: 2.25rem;
    }

    .year-recap-summary-item .label {
        font-size: 0.8rem;
    }

    .year-recap-actions {
        margin-top: 15px;
    }

    .year-recap-btn {
        padding: 10px 22px;
    }
}

/* Desktop with very limited height */
@media (min-width: 1024px) and (max-height: 700px) {
    .year-recap-slide {
        padding: 25px 30px 60px;
    }

    .year-recap-slide-summary .year-recap-user-thumbnail img {
        width: 50px !important;
        height: 50px !important;
        margin-bottom: 5px !important;
    }

    .year-recap-slide-summary .year-recap-title {
        font-size: 1.5rem !important;
        margin-bottom: 5px !important;
    }

    .year-recap-slide-summary .year-recap-subtitle {
        font-size: 0.9rem !important;
        margin-bottom: 8px !important;
    }

    .year-recap-summary-grid {
        margin: 10px auto;
        gap: 10px;
        max-width: 400px;
    }

    .year-recap-summary-item {
        padding: 12px 10px;
    }

    .year-recap-summary-item .number {
        font-size: 1.75rem;
    }

    .year-recap-summary-item .label {
        font-size: 0.7rem;
    }

    .year-recap-actions {
        margin-top: 10px;
        gap: 10px;
    }

    .year-recap-btn {
        padding: 8px 18px;
        font-size: 0.85rem;
    }

    /* Hide footer elements if needed */
    .year-recap-slide-summary .year-recap-slide-content > p:last-of-type {
        margin-top: 10px !important;
        font-size: 0.75rem !important;
    }

    .year-recap-slide-summary .year-recap-slide-content > div:last-child {
        margin-top: 8px !important;
    }
}
