/* ============================================
   ROSRA Landing Page - Mobile-First
   UN-Habitat & SDG 11 Inspired Design

   Breakpoint strategy (min-width, mobile-first):
     - Base:    < 576px   (mobile portrait)
     - sm:     >= 576px   (mobile landscape)
     - md:     >= 768px   (tablet)
     - lg:     >= 992px   (desktop)
     - xl:    >= 1200px   (large desktop)
   ============================================ */

/* CSS Variables - UN-Habitat Official Brand Colors */
:root {
    /* ============================================
       PRIMARY COLOURS (UN-Habitat Brand)
       ============================================ */

    /* UN-Habitat Blue - Main brand color */
    --un-blue: #00b2e3;
    --un-blue-rgb: 0, 178, 227;

    /* Black */
    --un-black: #000000;

    /* White */
    --un-white: #ffffff;

    /* ============================================
       SECONDARY COLOURS (Accent Colors)
       ============================================ */

    /* Green - PANTONE 360C */
    --un-green: #6dbe4b;
    --un-green-rgb: 109, 190, 75;

    /* Dark Blue - PANTONE 7462C */
    --un-dark-blue: #00689D;
    --un-dark-blue-rgb: 0, 104, 157;

    /* Red - PANTONE 805C */
    --un-red: #ff7276;
    --un-red-rgb: 255, 114, 118;

    /* Orange - PANTONE 1375C */
    --un-orange: #FD9D24;
    --un-orange-rgb: 253, 157, 36;

    /* Grey - PANTONE Cool Gray 8C */
    --un-grey: #888b8d;
    --un-grey-rgb: 136, 139, 141;

    /* Teal - PANTONE 326C */
    --un-teal: #00b2a9;
    --un-teal-rgb: 0, 178, 169;

    /* ============================================
       LEGACY ALIASES (for compatibility)
       ============================================ */
    --sdg11-orange: var(--un-orange);
    --sdg11-orange-dark: #E8891A;
    --sdg11-orange-light: #FFAD42;
    --primary-orange: var(--un-orange);
    --primary-orange-dark: #E8891A;
    --primary-orange-light: #FFAD42;

    /* Blue variants */
    --un-blue-dark: var(--un-dark-blue);
    --un-blue-light: #4DD4F7;
    --un-cyan: var(--un-blue);

    /* Dark backgrounds */
    --un-navy: #1a1a2e;
    --un-navy-light: #2d2d4a;

    /* Text colors */
    --text-dark: #1f2937;
    --text-muted: #6b7280;
    --text-light: #9ca3af;

    /* Backgrounds */
    --bg-light: #f8f9fa;
    --bg-accent: #fff8f0;
    --bg-un-light: #E6F9FC;
    --white: #ffffff;

    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;
}

/* ============================================
   FULL WIDTH SECTION BASE STYLES
   ============================================ */
.full-width-section {
    width: 100%;
    padding: 48px 0;
    position: relative;
    overflow: hidden;
}

.section-light { background: var(--white); }
.section-dark { background: var(--un-dark-blue); }
.section-accent { background: var(--bg-accent); }

.section-featured {
    background: var(--un-blue);
    position: relative;
}

.featured-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="50" cy="50" r="1" fill="rgba(255,255,255,0.03)"/></svg>');
    background-size: 30px 30px;
    pointer-events: none;
}

.section-testimonials { background: var(--un-blue); }

/* ============================================
   SECTION HEADERS
   ============================================ */
.section-header { margin-bottom: 32px; }

.section-badge {
    display: inline-block;
    background: rgba(249, 157, 38, 0.1);
    color: var(--primary-orange);
    padding: 6px 16px;
    border-radius: 50px;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    margin-bottom: 12px;
    border: 2px solid rgba(249, 157, 38, 0.2);
}

.section-badge.badge-light {
    background: rgba(255, 255, 255, 0.15);
    color: var(--white);
    border-color: rgba(255, 255, 255, 0.3);
}

.section-badge.badge-dark {
    background: var(--un-navy);
    color: var(--white);
    border-color: var(--un-navy);
}

.section-title {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--text-dark);
    margin-bottom: 16px;
    letter-spacing: -0.3px;
    line-height: 1.2;
}

.section-title.text-white { color: var(--white); }

.section-divider {
    width: 60px;
    height: 4px;
    background: var(--primary-orange);
    margin: 0 auto;
    border-radius: 2px;
}

.section-divider.divider-light { background: rgba(255, 255, 255, 0.5); }

/* ============================================
   HERO SECTION - UN-Habitat Style (mobile-first)
   ============================================ */
.hero-container {
    margin-top: 12px;
    padding: 0 16px;
}

.hero-section {
    position: relative;
    width: 100%;
    aspect-ratio: 4 / 3;
    overflow: hidden;
}

.hero-slides {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 0;
}

.hero-slide {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    opacity: 0;
    transition: opacity 1s ease-in-out;
}

.hero-slide.active { opacity: 1; }

.hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

/* Dark gradient for text readability */
.hero-gradient {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        to top,
        rgba(0, 0, 0, 0.75) 0%,
        rgba(0, 0, 0, 0.45) 35%,
        rgba(0, 0, 0, 0.1) 70%,
        rgba(0, 0, 0, 0) 100%
    );
    z-index: 1;
    pointer-events: none;
}

.hero-content {
    position: absolute;
    bottom: 40px;
    left: 0;
    right: 0;
    z-index: 2;
    padding: 0 20px;
}

.hero-title {
    font-size: 1.4rem;
    font-weight: 700;
    color: #ffffff;
    line-height: 1.25;
    margin-bottom: 18px;
    max-width: 100%;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.btn-hero-learn-more {
    display: inline-block;
    padding: 10px 22px;
    background: var(--un-blue);
    color: #ffffff;
    font-weight: 700;
    font-size: 0.8rem;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 1px;
    border: none;
    min-height: 44px;
    line-height: 1.5;
    transition: background var(--transition-normal);
}

.btn-hero-learn-more:hover,
.btn-hero-learn-more:focus {
    background: var(--un-blue-dark);
    color: #ffffff;
}

.hero-indicators {
    position: absolute;
    bottom: 14px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
    display: flex;
    gap: 8px;
}

.hero-indicators .indicator {
    width: 28px;
    height: 4px;
    background: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    transition: background var(--transition-fast);
}

.hero-indicators .indicator.active { background: #ffffff; }

.hero-indicators .indicator:hover { background: rgba(255, 255, 255, 0.7); }

/* ============================================
   UN-HABITAT LAYOUT STYLES (mobile-first)
   ============================================ */

/* --- Base Section --- */
.uh-section { padding: 40px 0; }

.uh-section--light { background: var(--bg-light); }

.uh-section--blue {
    background: var(--un-blue);
    color: #fff;
}

.uh-section-title {
    text-align: center;
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 10px;
    line-height: 1.25;
}

.uh-section--blue .uh-section-title { color: #fff; }

.uh-section-subtitle {
    text-align: center;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto 28px;
    font-size: 0.9rem;
    line-height: 1.6;
    padding: 0 4px;
}

.uh-section--blue .uh-section-subtitle { color: rgba(255,255,255,0.85); }

/* --- UN-Habitat Button --- */
.uh-btn {
    display: inline-block;
    padding: 12px 22px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-decoration: none;
    border: 2px solid;
    min-height: 44px;
    line-height: 1.4;
    transition: all var(--transition-normal);
}

.uh-btn--outline {
    color: var(--text-dark);
    border-color: var(--text-dark);
    background: transparent;
}

.uh-btn--outline:hover,
.uh-btn--outline:focus {
    background: var(--text-dark);
    color: #fff;
}

.uh-btn--outline-light {
    color: #fff;
    border-color: #fff;
    background: transparent;
}

.uh-btn--outline-light:hover,
.uh-btn--outline-light:focus {
    background: #fff;
    color: var(--un-blue);
}

.uh-btn--dark {
    color: #fff;
    border-color: var(--un-navy);
    background: var(--un-navy);
}

.uh-btn--dark:hover,
.uh-btn--dark:focus {
    background: #000;
    border-color: #000;
    color: #fff;
}

/* --- Featured Highlights Row --- */
.uh-featured-row {
    padding: 0;
    margin-top: 16px;
    margin-bottom: 16px;
}

.featured-cards {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
}

.featured-card { padding: 24px 20px; }

.featured-card h3 {
    font-size: 1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 10px;
}

.featured-card h4 {
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 10px;
}

.featured-card p {
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 14px;
}

.featured-card--primary {
    background: var(--un-blue);
    color: #fff;
}

.featured-card--accent {
    background: var(--un-orange);
    color: #fff;
}

.featured-card--white {
    background: #fff;
    color: var(--text-dark);
    border: 1px solid #e5e7eb;
}

/* --- Info Cards --- */
.uh-card-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    margin-bottom: 20px;
}

.uh-card-grid--centered {
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
}

.uh-info-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    overflow: hidden;
    transition: box-shadow var(--transition-normal);
}

.uh-info-card:hover { box-shadow: 0 4px 20px rgba(0,0,0,0.1); }

.uh-info-card__img {
    width: 100%;
    height: 160px;
    overflow: hidden;
}

.uh-info-card__img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

.uh-info-card:hover .uh-info-card__img img { transform: scale(1.05); }

/* SVG illustration variant — show whole artwork (no crop) */
.uh-info-card__img--svg {
    background: linear-gradient(135deg, #E6F7FC 0%, #C5EAF6 100%);
}

.uh-info-card__img--svg img {
    object-fit: contain;
    padding: 8px;
}

.uh-info-card:hover .uh-info-card__img--svg img { transform: scale(1.03); }

.uh-info-card__body { padding: 16px; }

.uh-info-card__body h4 {
    font-size: 0.95rem;
    font-weight: 700;
    margin-bottom: 6px;
    color: var(--text-dark);
}

.uh-info-card__body p {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.5;
    margin: 0;
}

/* --- Publication / Scroll Row (horizontal scroll on mobile) --- */
.uh-scroll-row {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    padding: 4px 4px 12px;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x mandatory;
    scrollbar-width: thin;
}

/* --- Carousel wrapper (arrows + dots around .uh-scroll-row) --- */
.uh-carousel {
    position: relative;
}

.uh-carousel__btn {
    position: absolute;
    top: calc(50% - 14px);
    transform: translateY(-50%);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #fff;
    border: 1px solid #e5e7eb;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--un-blue, #009edb);
    font-size: 0.9rem;
    cursor: pointer;
    z-index: 2;
    transition: background 0.2s, color 0.2s, opacity 0.2s;
}

.uh-carousel__btn:hover:not(:disabled) {
    background: var(--un-blue, #009edb);
    color: #fff;
}

.uh-carousel__btn:disabled {
    opacity: 0.3;
    cursor: default;
}

.uh-carousel__btn--prev { left: -6px; }
.uh-carousel__btn--next { right: -6px; }

.uh-carousel__dots {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-top: 8px;
}

.uh-carousel__dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #d1d5db;
    border: none;
    padding: 0;
    cursor: pointer;
    transition: background 0.2s, width 0.2s, border-radius 0.2s;
}

.uh-carousel__dot.is-active {
    background: var(--un-blue, #009edb);
    width: 22px;
    border-radius: 4px;
}

.uh-pub-card {
    flex: 0 0 155px;
    text-align: center;
    padding: 18px 12px;
    background: #fff;
    border: 1px solid #e5e7eb;
    scroll-snap-align: start;
    transition: box-shadow var(--transition-normal);
}

.uh-pub-card:hover { box-shadow: 0 4px 16px rgba(0,0,0,0.08); }

.uh-pub-icon {
    width: 52px;
    height: 52px;
    background: var(--bg-un-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 10px;
    color: var(--un-blue);
    font-size: 1.25rem;
}

.uh-pub-card h4 {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 6px;
}

.uh-pub-card p {
    font-size: 0.75rem;
    color: var(--text-muted);
    line-height: 1.4;
    margin: 0;
}

/* --- Our Focus (Blue section with icons) --- */
.uh-focus-label {
    text-align: center;
    color: var(--un-orange);
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 14px;
}

.uh-focus-desc {
    text-align: center;
    color: rgba(255,255,255,0.9);
    max-width: 600px;
    margin: 0 auto 24px;
    font-size: 0.9rem;
    line-height: 1.6;
}

.uh-focus-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 22px;
    margin-bottom: 24px;
}

.uh-focus-item { text-align: center; }

.uh-focus-icon {
    width: 56px;
    height: 56px;
    border: 2px solid rgba(255,255,255,0.4);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 12px;
    font-size: 1.3rem;
    color: #fff;
}

.uh-focus-item p {
    font-size: 0.9rem;
    line-height: 1.5;
    color: rgba(255,255,255,0.9);
}

/* --- Icon Cards (Why UN-Habitat) --- */
.uh-icon-cards {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    margin-top: 28px;
}

.uh-icon-card {
    text-align: center;
    padding: 24px 18px;
    border: 1px solid #e5e7eb;
    background: #fff;
    transition: box-shadow var(--transition-normal);
}

.uh-icon-card:hover { box-shadow: 0 6px 24px rgba(0,0,0,0.08); }

.uh-icon-card__img {
    width: 70px;
    height: 70px;
    margin: 0 auto 16px;
}

.uh-icon-card__img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.uh-icon-card h4 {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.uh-icon-card p {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.5;
    margin: 0;
}

/* --- Flagship Cards --- */
.uh-flagship-card {
    position: relative;
    height: 180px;
    overflow: hidden;
    background: var(--bg-light);
    border: 1px solid #e5e7eb;
}

.uh-flagship-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

.uh-flagship-card:hover img { transform: scale(1.05); }

.uh-flagship-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 12px 16px;
    background: linear-gradient(to top, rgba(0,0,0,0.7), transparent);
}

.uh-flagship-overlay span {
    color: #fff;
    font-size: 0.85rem;
    font-weight: 700;
}

/* --- SDG Section --- */
.uh-sdg-section {
    background: var(--bg-light);
    padding: 36px 0;
}

.uh-sdg-grid {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 14px;
    margin: 22px 0 14px;
}

.uh-sdg-grid a { transition: transform var(--transition-fast); }

.uh-sdg-grid a:hover { transform: scale(1.08); }

.uh-sdg-grid img {
    width: 76px;
    height: 76px;
}

.uh-sdg-note {
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-muted);
    padding: 0 16px;
}

/* --- Animation --- */
.uh-info-card,
.uh-pub-card,
.uh-focus-item,
.uh-flagship-card {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease, box-shadow var(--transition-normal);
}

.uh-info-card.animate-in,
.uh-pub-card.animate-in,
.uh-focus-item.animate-in,
.uh-flagship-card.animate-in {
    opacity: 1;
    transform: translateY(0);
}

/* Respect reduced motion preferences */
@media (prefers-reduced-motion: reduce) {
    .uh-info-card,
    .uh-pub-card,
    .uh-focus-item,
    .uh-flagship-card,
    .hero-slide,
    .uh-info-card__img img,
    .uh-flagship-card img {
        transition: none;
        transform: none;
        opacity: 1;
    }
}

/* ============================================
   PROGRESSIVE ENHANCEMENT - min-width breakpoints
   ============================================ */

/* --- sm: >= 576px (large phones / small tablets) --- */
@media (min-width: 576px) {
    .hero-container {
        margin-top: 16px;
        padding: 0 24px;
    }

    .hero-section { aspect-ratio: 16 / 9; }

    .hero-content {
        bottom: 50px;
        padding: 0 28px;
    }

    .hero-title {
        font-size: 1.75rem;
        max-width: 560px;
    }

    .hero-indicators { gap: 10px; }

    .hero-indicators .indicator { width: 32px; }

    .uh-card-grid { gap: 20px; }

    .uh-card-grid--2col,
    .uh-card-grid--3col {
        grid-template-columns: repeat(2, 1fr);
    }

    .uh-focus-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 26px;
    }

    .uh-icon-cards {
        grid-template-columns: repeat(2, 1fr);
        gap: 22px;
    }

    .uh-sdg-grid { gap: 20px; }
    .uh-sdg-grid img { width: 90px; height: 90px; }

    .uh-section-title { font-size: 1.55rem; }
    .section-title { font-size: 2.1rem; }
}

/* --- md: >= 768px (tablets) --- */
@media (min-width: 768px) {
    .full-width-section { padding: 72px 0; }

    .hero-container { padding: 0 56px; }

    .hero-section { aspect-ratio: 2 / 1; }

    .hero-content {
        bottom: 60px;
        padding: 0 5%;
    }

    .hero-title {
        font-size: 2.2rem;
        max-width: 620px;
    }

    .hero-indicators { bottom: 18px; }

    .hero-indicators .indicator { width: 36px; }

    .uh-section { padding: 56px 0; }

    .uh-section-title { font-size: 1.7rem; }

    .featured-cards {
        grid-template-columns: 2fr 1.2fr 1fr;
        gap: 0;
    }

    .uh-card-grid--3col {
        grid-template-columns: repeat(3, 1fr);
    }

    .uh-scroll-row {
        flex-wrap: wrap;
        justify-content: center;
        overflow-x: visible;
        scroll-snap-type: none;
        gap: 18px;
    }

    .uh-pub-card { flex: 0 0 160px; }

    .uh-carousel__btn,
    .uh-carousel__dots { display: none; }

    .uh-focus-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 26px;
    }

    .uh-icon-cards {
        grid-template-columns: repeat(4, 1fr);
        gap: 26px;
    }
}

/* --- lg: >= 992px (desktop) --- */
@media (min-width: 992px) {
    .full-width-section { padding: 100px 0; }

    .hero-container {
        margin-top: 20px;
        padding: 0 80px;
    }

    .hero-section { aspect-ratio: 5 / 2; }

    .hero-content {
        bottom: 80px;
        padding: 0 5%;
    }

    .hero-title {
        font-size: 2.8rem;
        max-width: 700px;
        margin-bottom: 24px;
    }

    .btn-hero-learn-more {
        padding: 10px 28px;
        font-size: 0.85rem;
    }

    .hero-indicators {
        bottom: 20px;
        gap: 10px;
    }

    .hero-indicators .indicator { width: 40px; }

    .uh-section { padding: 60px 0; }

    .uh-section-title { font-size: 1.8rem; }

    .section-title { font-size: 2.75rem; }

    .uh-sdg-section { padding: 50px 0; }

    .uh-sdg-grid img { width: 100px; height: 100px; }

    .uh-focus-grid,
    .uh-icon-cards { gap: 30px; }

    .uh-card-grid--centered { max-width: 66%; }
}

/* --- xl: >= 1200px (large desktop) --- */
@media (min-width: 1200px) {
    .hero-container { padding: 0 140px; }
}

/* ============================================================
   How ROSRA Works — methodology section with screenshot rows
   ============================================================ */
.rosra-method-row {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    gap: 3rem;
    align-items: center;
    margin: 3.5rem auto;
    max-width: 1140px;
}

.rosra-method-row--reverse .rosra-method-img { order: 2; }
.rosra-method-row--reverse .rosra-method-text { order: 1; }

.rosra-method-img {
    background: #ffffff;
    border-radius: 14px;
    padding: 0.75rem;
    box-shadow: 0 18px 40px -22px rgba(15, 23, 42, 0.45),
                0 4px 14px -8px rgba(15, 23, 42, 0.12);
    border: 1px solid #E6EDF3;
}

.rosra-method-img img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 8px;
}

.rosra-method-text { padding: 0.5rem 0; }

.rosra-method-step {
    display: inline-block;
    background: #00B2E3;
    color: #ffffff;
    font-weight: 700;
    font-size: 0.72rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
    margin-bottom: 0.85rem;
}

.rosra-method-heading {
    font-size: 1.55rem;
    font-weight: 700;
    color: #00689D;
    margin: 0 0 0.85rem;
    line-height: 1.2;
}

.rosra-method-heading i {
    color: #FD9D24;
    font-size: 1.3rem;
}

.rosra-method-text p {
    font-size: 0.98rem;
    line-height: 1.65;
    color: #334155;
    margin: 0;
}

.rosra-method-text p strong { color: #1f2937; }

@media (max-width: 767.98px) {
    .rosra-method-row,
    .rosra-method-row--reverse {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        margin: 2.25rem auto;
    }
    .rosra-method-row--reverse .rosra-method-img { order: 0; }
    .rosra-method-row--reverse .rosra-method-text { order: 0; }
    .rosra-method-heading { font-size: 1.3rem; }
}

/* ============================================
   Process flow diagram — visual TOC at top of the methodology section.
   5 cards in a row, arrows between them, phase timeline below.
   Brand palette: cyan #00B2E3, navy #0F2742, teal #1F7B5A, accent orange #FD9D24.
   ============================================ */
.rosra-flow {
    max-width: 1240px;
    margin: 2rem auto 3.5rem;
    padding: 1rem 0;
}

/* Shared column template for cards + phases so the timeline aligns under each card.
   Columns: card1 | arrow | card2-wide | arrow | card3 | arrow | card4 | arrow | card5 */
.rosra-flow__cards {
    display: grid;
    grid-template-columns: 1fr 28px 2.4fr 28px 1fr 28px 1fr 28px 1fr;
    align-items: stretch;
    gap: 0.5rem;
}

.rosra-flow__card {
    min-width: 0;
    background: #ffffff;
    border: 2px solid #00B2E3;
    border-radius: 14px;
    padding: 2rem 1rem 1.25rem;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    text-align: center;
    box-shadow: 0 6px 18px -10px rgba(15, 23, 42, 0.18);
}

.rosra-flow__card--teal      { border-color: #1F7B5A; background: #F2FBF7; }
.rosra-flow__card--green     { border-color: #1F7B5A; }
.rosra-flow__card--report    { border-style: dashed; border-color: #B0BEC9; background: transparent; box-shadow: none; }
.rosra-flow__card--wide      { padding-bottom: 1.5rem; }

.rosra-flow__num {
    position: absolute;
    top: -16px;
    left: 50%;
    transform: translateX(-50%);
    width: 34px; height: 34px;
    border-radius: 50%;
    background: #0F2742;
    color: #ffffff;
    font-size: 1.05rem;
    font-weight: 700;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.25);
}
.rosra-flow__num--teal  { background: #1F7B5A; }
.rosra-flow__num--green { background: #1F7B5A; }

.rosra-flow__title {
    font-size: 1.05rem;
    font-weight: 700;
    color: #0F2742;
    margin: 0.25rem 0 0.4rem;
    line-height: 1.2;
}
.rosra-flow__title--teal   { color: #155F46; }
.rosra-flow__title--green  { color: #155F46; }
.rosra-flow__title--report { color: #0F2742; margin-top: 0.8rem; }

.rosra-flow__sub {
    font-size: 0.8rem;
    line-height: 1.4;
    color: #475569;
    margin: 0 0 0.85rem;
}

.rosra-flow__icon {
    margin: 0.5rem auto 0;
    width: 70px; height: 70px;
}
.rosra-flow__icon svg { width: 100%; height: 100%; display: block; }
.rosra-flow__icon--navy { color: #0F2742; }
.rosra-flow__icon--teal { color: #1F7B5A; }

.rosra-flow__arrow {
    align-self: center;
    justify-self: center;
    width: 28px; height: 28px;
    color: #0F2742;
}

/* Stream-specific gap sub-cards (Card 2) */
.rosra-flow__streams {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.55rem;
    margin-top: 0.2rem;
}
.rosra-flow__stream {
    background: #ffffff;
    border: 1px solid #E0E7EB;
    border-radius: 8px;
    padding: 0.7rem 0.55rem 0.6rem;
    text-align: left;
}
.rosra-flow__stream--green { background: #EAF6EE; border-color: #C7E4D2; }
.rosra-flow__stream-head {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    font-weight: 700;
    color: #0F2742;
    font-size: 0.82rem;
    padding-bottom: 0.4rem;
    border-bottom: 1px solid #E0E7EB;
    margin-bottom: 0.4rem;
}
.rosra-flow__stream-head i { color: #1F7B5A; font-size: 0.95rem; }
.rosra-flow__gaps {
    list-style: none;
    margin: 0;
    padding: 0;
}
.rosra-flow__gaps li {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.74rem;
    color: #334155;
    padding: 0.18rem 0;
}
.rosra-flow__gaps li i { color: #1F7B5A; width: 14px; font-size: 0.75rem; }

/* Prioritization ranked bars (Card 3) */
.rosra-flow__rank {
    list-style: none;
    margin: 0.4rem 0 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}
.rosra-flow__rank li {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}
.rosra-flow__rank-num {
    width: 22px; height: 22px;
    border-radius: 50%;
    background: #0F2742;
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 700;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.rosra-flow__rank-bar {
    flex: 1;
    height: 6px;
    border-radius: 999px;
}
.rosra-flow__rank-bar--1 { background: #0F2742; }
.rosra-flow__rank-bar--2 { background: #00B2E3; }
.rosra-flow__rank-bar--3 { background: #B8E5F2; }

/* Phase timeline — same grid template as the cards row so each phase sits under its card.
   Phase 5 (report) is intentionally omitted; the 5th column is left empty. */
.rosra-flow__phases {
    display: grid;
    grid-template-columns: 1fr 28px 2.4fr 28px 1fr 28px 1fr 28px 1fr;
    gap: 0.5rem;
    margin: 1.25rem auto 0;
}
.rosra-flow__phase {
    position: relative;
    padding-top: 1rem;
    text-align: center;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.3px;
    line-height: 1.3;
}
.rosra-flow__phase::before {
    content: '';
    position: absolute;
    top: 0; left: 8%; right: 8%;
    height: 2px;
    border-radius: 1px;
}
.rosra-flow__phase::after {
    content: '';
    position: absolute;
    top: -3px; right: 8%;
    width: 8px; height: 8px;
    border-radius: 50%;
    transform: translateX(50%);
}
.rosra-flow__phase--cyan  { color: #00689D; grid-column: 1; }
.rosra-flow__phase--teal  { color: #155F46; grid-column: 3; }
.rosra-flow__phase--blue  { color: #00689D; grid-column: 5; }
.rosra-flow__phase--green { color: #155F46; grid-column: 7; }
.rosra-flow__phase--cyan::before,  .rosra-flow__phase--cyan::after  { background: #00B2E3; }
.rosra-flow__phase--teal::before,  .rosra-flow__phase--teal::after  { background: #1F7B5A; }
.rosra-flow__phase--blue::before,  .rosra-flow__phase--blue::after  { background: #00689D; }
.rosra-flow__phase--green::before, .rosra-flow__phase--green::after { background: #1F7B5A; }

/* Responsive — stack cards vertically on narrow viewports */
@media (max-width: 991.98px) {
    .rosra-flow__cards {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }
    .rosra-flow__arrow {
        transform: rotate(90deg);
        justify-self: center;
    }
    .rosra-flow__phases {
        grid-template-columns: 1fr;
        gap: 0.4rem;
        margin-top: 1rem;
    }
    .rosra-flow__phase,
    .rosra-flow__phase--cyan,
    .rosra-flow__phase--teal,
    .rosra-flow__phase--blue,
    .rosra-flow__phase--green {
        grid-column: 1;
        padding: 0.5rem 0 0 1.2rem;
        text-align: left;
    }
    .rosra-flow__phase::before {
        top: 0; left: 0; right: auto;
        width: 4px; height: 100%;
        border-radius: 2px;
    }
    .rosra-flow__phase::after {
        top: 50%; left: 2px; right: auto;
        transform: translate(-50%, -50%);
    }
}

/* ============================================
   Hero subtitle + action buttons (homepage rewrite)
   ============================================ */
.hero-subtitle {
    color: rgba(255, 255, 255, 0.92);
    font-size: 0.95rem;
    line-height: 1.5;
    margin: 0 0 18px;
    max-width: 720px;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.35);
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.btn-hero-primary,
.btn-hero-secondary {
    display: inline-block;
    padding: 10px 22px;
    font-weight: 700;
    font-size: 0.85rem;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 1px;
    min-height: 44px;
    line-height: 1.5;
    transition: background var(--transition-normal), color var(--transition-normal), border-color var(--transition-normal);
}

.btn-hero-primary {
    background: var(--un-blue);
    color: #ffffff;
    border: 2px solid var(--un-blue);
}
.btn-hero-primary:hover,
.btn-hero-primary:focus {
    background: var(--un-blue-dark, #008cbb);
    border-color: var(--un-blue-dark, #008cbb);
    color: #ffffff;
}

.btn-hero-secondary {
    background: transparent;
    color: #ffffff;
    border: 2px solid #ffffff;
}
.btn-hero-secondary:hover,
.btn-hero-secondary:focus {
    background: #ffffff;
    color: var(--un-blue);
}

@media (min-width: 768px) {
    .hero-subtitle { font-size: 1.05rem; margin-bottom: 22px; }
}

/* ============================================
   Compact OSR streams chips
   ============================================ */
.rosra-streams-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    justify-content: center;
    max-width: 920px;
    margin: 1.25rem auto 0;
}

.rosra-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.55rem 0.95rem;
    background: #ffffff;
    border: 1px solid #d6dde3;
    border-radius: 999px;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--un-dark-blue);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}

.rosra-chip i {
    color: var(--un-blue);
    font-size: 0.9rem;
}

/* ============================================
   Supported by UN-Habitat (compact section)
   ============================================ */
.rosra-unhabitat {
    max-width: 720px;
    margin: 0 auto;
    text-align: center;
}

.rosra-unhabitat__body {
    color: #4a5560;
    line-height: 1.55;
    font-size: 1rem;
    margin: 0;
}