/* REVEMARK SITE CSS - STABLE RESTORATION */

/* =========================================
   1. DESIGN TOKENS
   ========================================= */
:root {
    --primary-yellow: #fcbf37;
    --primary-yellow-soft: rgba(252, 191, 55, 0.22);
    --primary-yellow-faint: rgba(252, 191, 55, 0.08);

    /* Brand Colors */
    --primary-color: var(--primary-yellow);
    /* Scientific Gold */
    --primary-hover: var(--primary-yellow);

    /* Neutral / Surfaces */
    --bg-color: #0F0F10;
    --surface-color: #18181B;
    --border-color: #27272A;

    /* Text */
    --text-primary: #F2F2F2;
    --text-secondary: #A1A1AA;

    /* Typography */
    --font-main: 'Outfit', system-ui, sans-serif;

    /* Spacing */
    --space-md: 24px;
    --space-lg: 48px;
}

/* =========================================
   2. GLOBAL RESET & BASE
   ========================================= */
body {
    margin: 0;
    background-color: var(--bg-color);
    background:
        linear-gradient(135deg, rgba(252, 191, 55, 0.06) 0 1px, transparent 1px 80px),
        radial-gradient(circle at 18% 12%, rgba(252, 191, 55, 0.12), transparent 34%),
        linear-gradient(140deg, #171716 0%, #0f0f10 48%, #09090a 100%);
    background-attachment: fixed;
    color: var(--text-primary);
    font-family: var(--font-main);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    line-height: 1.5;
    border-top: 5px solid var(--primary-yellow);
    position: relative;
    overflow-x: hidden;
}

body::before {
    content: "";
    position: fixed;
    inset: 72px 0 0 auto;
    width: min(58vw, 720px);
    min-width: 420px;
    height: min(82vh, 760px);
    pointer-events: none;
    opacity: 0.18;
    background-image: url("data:image/svg+xml,%3Csvg width='720' height='760' viewBox='0 0 720 760' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cg stroke='%23fcbf37' stroke-width='11' stroke-linecap='round' opacity='0.9'%3E%3Cpath d='M359 677c-89-48-145-137-145-247 0-93 54-164 139-164 91 0 149 68 149 157 0 71-34 126-86 163'/%3E%3Cpath d='M310 702c-103-62-169-164-169-283 0-134 86-232 213-232 129 0 221 97 221 231 0 91-39 169-109 224'/%3E%3Cpath d='M246 721C123 645 55 531 55 408c0-174 126-302 297-302 176 0 306 130 306 306 0 107-43 210-130 284'/%3E%3Cpath d='M401 521c22-31 35-61 35-98 0-55-31-92-80-92-47 0-77 37-77 94 0 91 41 161 113 210'/%3E%3Cpath d='M356 447c-16-48-11-72 12-72 22 0 34 18 34 49 0 29-8 51-24 71'/%3E%3Cpath d='M282 604c-63-55-96-118-96-188 0-106 68-183 168-183 103 0 177 76 177 182 0 78-35 145-94 198'/%3E%3Cpath d='M203 656C122 589 85 506 85 409c0-158 113-273 267-273 159 0 277 116 277 275 0 110-50 207-138 272'/%3E%3C/g%3E%3C/svg%3E");
    background-position: right 16% center;
    background-repeat: no-repeat;
    background-size: contain;
    filter: drop-shadow(0 0 26px rgba(252, 191, 55, 0.18));
    z-index: 0;
}

body > * {
    position: relative;
    z-index: 1;
}

.background-globes {
    display: none;
}

/* =========================================
   3. LAYOUT STRUCTURE
   ========================================= */
header {
    background: rgba(15, 15, 16, 0.88);
    /* Slight transaprency */
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(8px);
    /* Safe modern blur */
}

main {
    max-width: 1200px;
    margin: 0 auto;
    padding: var(--space-lg) 16px;
    width: 100%;
    box-sizing: border-box;
    flex: 1;
    /* Sticky footer behavior */
}

footer {
    background: rgba(18, 18, 19, 0.92);
    border-top: 1px solid var(--border-color);
    padding: 32px 0;
    text-align: center;
    margin-top: auto;
}

section {
    margin-bottom: var(--space-lg);
}

/* =========================================
   4. TYPOGRAPHY
   ========================================= */
h1,
h2,
h3,
h4 {
    color: var(--text-primary);
    margin-top: 0;
    font-weight: 600;
}

h1 {
    font-size: 2.5rem;
}

h2 {
    font-size: 2rem;
}

h3 {
    font-size: 1.5rem;
}

a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: var(--primary-color);
}

.text-brand {
    color: var(--primary-color);
}

.text-muted {
    color: var(--text-secondary);
}

.hero-title {
    text-align: center;
    font-size: clamp(2.15rem, 4vw, 3.35rem);
    font-weight: 700;
    margin-bottom: 24px;
    letter-spacing: 0;
}

.hero-content {
    text-align: center;
    max-width: 920px;
    min-height: auto;
    padding-top: 40px;
    padding-bottom: 10px;
}

.hero-description {
    text-align: justify;
    max-width: 800px;
    margin: 0 auto 32px auto;
    font-size: 1.15rem;
    line-height: 1.75;
    color: #cfcfcf;
}

.hero-section {
    position: relative;
}

.hero-section::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: -22px;
    width: min(760px, 82vw);
    height: 1px;
    transform: translateX(-50%);
    background: linear-gradient(90deg, transparent, var(--primary-yellow), transparent);
    opacity: 0.5;
}

/* =========================================
   5. COMPONENTS: BUTTONS (Phase 2)
   ========================================= */
button.btn-primary,
.btn-primary {
    background-color: var(--primary-color);
    color: #000000;
    border: none;
    padding: 12px 24px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 4px;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    display: inline-block;
    text-align: center;
    background-color: var(--primary-yellow) !important;
    color: #000 !important;
}

button.btn-primary:hover,
.btn-primary:hover {
    background-color: var(--primary-yellow);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px var(--primary-yellow-soft);
}

button.btn-secondary,
.btn-secondary {
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    padding: 10px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s ease;
}

button.btn-secondary:hover:not(:disabled) {
    border-color: var(--text-primary);
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

.btn-upload,
.btn-camera {
    background: var(--primary-yellow);
    color: #000;
    padding: 14px 28px;
    border-radius: 40px;
    font-weight: 600;
    cursor: pointer;
    display: inline-block;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn-upload:hover,
.btn-camera:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

/* =========================================
   6. COMPONENTS: RIS WORKSPACE
   ========================================= */
.ris-analysis {
    display: flex;
    justify-content: center;
    margin-bottom: 60px;
}

.analysis-card {
    width: 100%;
    max-width: 720px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 14px;
    padding: 40px;
}

.analysis-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.analysis-header h2 {
    font-size: 1.6rem;
    color: #fff;
}

.analysis-tag {
    background: var(--primary-yellow);
    color: #000;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.upload-zone {
    text-align: center;
    padding: 30px;
    border-radius: 10px;
    background: rgba(0, 0, 0, 0.4);
}

.upload-zone p {
    font-size: 1.1rem;
    margin-bottom: 6px;
    color: #ffffff;
}

.upload-zone small {
    color: #9c9c9c;
    display: block;
    margin-bottom: 24px;
}

.upload-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
}

.btn-outline {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: #fff;
    padding: 12px 24px;
    border-radius: 30px;
    cursor: pointer;
    font-weight: 600;
    transition: 0.2s ease;
}

.btn-outline:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: #fff;
}

/* Pipeline Visualization */
.step {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #333;
    position: relative;
}

.step.active .step-dot {
    background: var(--primary-color);
    box-shadow: 0 0 10px var(--primary-color);
}

.step.completed {
    background: var(--primary-color);
}

.step-line {
    width: 40px;
    height: 2px;
    background: #333;
    margin-top: 5px;
}

/* Institutional Section (RIS) */
.pillars {
    margin-top: 60px;
    margin-bottom: 60px;
}

.ris-section {
    background: rgba(255, 255, 255, 0.02);
    padding: 60px 40px !important;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.05) !important;
    margin-top: 40px;
}

.ris-section h2 {
    font-size: 1.8rem;
    margin-bottom: 16px;
    color: #ffffff;
}

/* Ris Hero Restructure Phase 2 */
.ris-hero {
    text-align: center;
    margin-top: 40px;
    margin-bottom: 40px;
}

.ris-hero h1 {
    font-size: 2.8rem;
    font-weight: 700;
    color: var(--primary-yellow);
    margin-bottom: 12px;
    letter-spacing: 0.5px;
}

.ris-hero p {
    font-size: 1.15rem;
    color: #bcbcbc;
    max-width: 700px;
    margin: 0 auto;
}

/* Explicit RIS Tool Main Wrapper */
.ris-main {
    min-height: calc(100vh - 90px);
    padding-top: 20px;
    padding-bottom: 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

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

.ris-upload {
    max-width: 900px;
    margin: 0 auto;
}

.ris-section p {
    font-size: 1.05rem;
    color: #bbbbbb;
    max-width: 700px;
    margin: 0 auto;
}

.ris-cta {
    margin-top: 32px;
    text-align: center;
}

/* =========================================
    STRICT HEADER NORMALIZATION (User Request)
   ========================================= */
/* Strict Layout System (Anti-Shift) */
#site-header {
    height: 72px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 32px;
    background-color: rgba(15, 15, 16, 0.9);
    border-bottom: 1px solid rgba(252, 191, 55, 0.16);
    z-index: 1000;
    position: relative;
    box-sizing: border-box;
    /* Critical for padding */
}

#site-main {
    flex: 1;
    /* Push footer down */
    width: 100%;
    box-sizing: border-box;
    /* Vertical Rhythm Normalization */
    min-height: calc(100vh - 72px);
    padding-top: 48px;
    padding-bottom: 64px;
    max-width: 1200px;
    /* Retained from original main */
    margin: 0 auto;
    /* Retained from original main */
}

#site-main section {
    margin-bottom: 48px;
}

#site-footer {
    background: var(--surface-color);
    /* Retained from original footer */
    border-top: 1px solid var(--border-color);
    /* Retained from original footer */
    text-align: center;
    /* Retained from original footer */
    margin-top: auto;
    padding: 32px 0;
}

/* Logo */
#site-header .logo {
    display: flex;
    /* Ensure image aligns */
    align-items: center;
    font-size: 18px;
    font-weight: 600;
    line-height: 1;
    text-decoration: none;
    color: var(--text-primary);
}

#site-header .logo img {
    height: 38px;
    width: auto;
    display: block;
}

/* Menu */
#site-header nav {
    display: flex;
    align-items: center;
}

#site-header nav a {
    font-size: 14px;
    font-weight: 400;
    margin: 0 12px;
    text-decoration: none;
    color: var(--text-secondary);
    /* Default color */
    padding-bottom: 4px;
    /* Space for border */
    border-bottom: 2px solid transparent;
    transition: all 0.2s ease;
    font-family: var(--font-main);
    text-transform: uppercase;
    /* Optional: matches previous aesthetics if desired, but user didn't specify. Keeping simple per request. */
}

#site-header nav a:hover,
#site-header nav a.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

/* Idioma */
#site-header .lang-switch {
    font-size: 13px;
    display: flex;
    align-items: center;
}

/* Specific select styling for the strict structure */
#site-header .lang-switch select {
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    padding: 4px 8px;
    border-radius: 4px;
    font-family: var(--font-main);
    cursor: pointer;
    outline: none;
}

#site-header .lang-switch select:hover {
    border-color: var(--primary-color);
    color: var(--text-primary);
}

/* =========================================
   8. UTILITIES & GRID
   ========================================= */
.hidden {
    display: none !important;
}

.grid {
    display: grid;
    gap: 24px;
    grid-template-columns: 1fr;
}

.pillars-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 32px;
}

@media (min-width: 768px) {
    .grid {
        grid-template-columns: repeat(3, 1fr);
    }

    /* Special Institutional Layout */
    .institutional-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.glass-card {
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.045), rgba(255, 255, 255, 0.018)),
        rgba(24, 24, 27, 0.86);
    border: 1px solid rgba(252, 191, 55, 0.14);
    border-radius: 8px;
    padding: 24px;
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.22);
    transition: transform 0.2s ease, border-color 0.2s, background 0.2s ease;
}

@media (max-width: 900px) {
    #site-header {
        height: auto;
        min-height: 72px;
        align-items: flex-start;
        gap: 14px;
        padding: 16px 20px;
        flex-wrap: wrap;
    }

    #site-header nav {
        order: 3;
        width: 100%;
        justify-content: center;
        flex-wrap: wrap;
        row-gap: 10px;
    }

    #site-header nav a {
        min-height: 44px;
        display: inline-flex;
        align-items: center;
        margin: 0 8px;
    }

    #site-main {
        padding-top: 34px;
    }

    .pillars-grid {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .hero-description {
        text-align: left;
    }

    body::before {
        inset: 130px -180px auto auto;
        width: 620px;
        min-width: 620px;
        height: 660px;
        opacity: 0.12;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
    }
}

.glass-card:hover {
    border-color: var(--primary-color);
    transform: translateY(-2px);
    background:
        linear-gradient(180deg, rgba(252, 191, 55, 0.075), rgba(255, 255, 255, 0.022)),
        rgba(24, 24, 27, 0.9);
}

/* =========================================
   HERO BRAND SCALING FIX
   ========================================= */
.hero-brand.revemark-brand-hero,
.revemark-brand-hero {
    position: relative;
    width: min(760px, calc(100% - 48px));
    margin: 38px auto 18px;
    padding: 8px 24px;
    display: flex;
    justify-content: center;
    align-items: center;
    isolation: isolate;
    min-height: 0;
    height: auto;
    overflow: visible;
    background: transparent;
    border: 0;
    box-shadow: none;
    box-sizing: border-box;
}

.hero-brand.revemark-brand-hero::before,
.revemark-brand-hero::before {
    content: "";
    position: absolute;
    z-index: 0;
    width: 88%;
    height: 120%;
    left: 6%;
    top: -10%;
    background: radial-gradient(
        ellipse at center,
        rgba(214, 165, 46, 0.10) 0%,
        rgba(214, 165, 46, 0.035) 42%,
        transparent 72%
    );
    filter: blur(36px);
    pointer-events: none;
}

.logo-hero,
.hero-logo,
.revemark-main-logo {
    opacity: 0.85;
    filter: saturate(0.9) brightness(0.95) blur(0.25px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
    border-radius: 2px;
}

.hero-section .revemark-brand-hero > img.revemark-brand-logo[src$="revemark-transparent.png"] {
    display: block;
    position: relative;
    z-index: 2;
    width: min(460px, 78vw);
    max-width: 100%;
    height: auto;
    object-fit: contain;
    opacity: 0.90;
    filter:
        drop-shadow(0 10px 24px rgba(0, 0, 0, 0.32))
        drop-shadow(0 0 18px rgba(214, 165, 46, 0.08));
    pointer-events: none;
}

.hero-section .revemark-brand-hero + .hero-content {
    padding-top: 0;
}

.hero-section .home-revemark-brand {
    width: min(920px, calc(100% - 48px));
    margin: 42px auto 28px;
    padding: 12px 20px 4px;
}

.hero-section .home-revemark-brand > img.revemark-brand-logo[src$="revemark-transparent.png"] {
    width: min(760px, 82vw);
    max-width: 100%;
    height: auto;
    object-fit: contain;
    opacity: 0.94;
    filter:
        drop-shadow(0 10px 24px rgba(0, 0, 0, 0.30))
        drop-shadow(0 0 20px rgba(214, 165, 46, 0.10));
}

.hero-section .home-revemark-brand + .hero-content .hero-title {
    margin-top: 0;
}

.ris-tool-brand {
    margin: 0 0 18px 0;
}

.ris-brand-hero {
    margin-top: 0;
}

@media (max-width: 768px) {
    .hero-brand.revemark-brand-hero,
    .revemark-brand-hero {
        width: calc(100% - 32px);
        margin: 24px auto 18px;
        padding: 6px 12px;
    }

    .hero-section .revemark-brand-hero > img.revemark-brand-logo[src$="revemark-transparent.png"] {
        width: min(380px, 88vw);
        height: auto;
    }

    .hero-section .home-revemark-brand {
        width: calc(100% - 32px);
        margin: 28px auto 28px;
        padding: 8px 12px 2px;
    }

    .hero-section .home-revemark-brand > img.revemark-brand-logo[src$="revemark-transparent.png"] {
        width: min(520px, 88vw);
        height: auto;
    }

    .hero-section .home-revemark-brand + .hero-content .hero-title {
        margin-top: 0;
    }
}

/* Global image protection */
img {
    max-width: 100%;
    height: auto;
}

/* =========================================
   ANALYSIS RESULTS (Redesign)
   ========================================= */

.analysis-summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 30px 40px;
    border-radius: 14px;
    margin-bottom: 20px;
}

.final-score {
    text-align: center;
}

.score-label {
    font-size: 0.9rem;
    color: #aaa;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.score-value {
    font-size: 3.5rem;
    font-weight: 700;
    color: var(--primary-yellow);
    line-height: 1.1;
    margin: 5px 0;
}

.score-status {
    font-size: 1rem;
    color: #cfcfcf;
}

.analysis-classification {
    text-align: right;
    max-width: 50%;
}

.classification-badge {
    display: inline-block;
    background: var(--primary-yellow);
    color: #000;
    padding: 8px 18px;
    border-radius: 30px;
    font-weight: 600;
    margin-bottom: 8px;
    font-size: 1.1rem;
}

.analysis-classification p {
    color: #cfcfcf;
    font-size: 0.95rem;
    margin: 0;
}

.confidence-bar {
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}

.confidence-fill {
    height: 100%;
    background: var(--primary-yellow);
    border-radius: 4px;
    transition: width 0.6s ease-out;
}

.metrics-panel {
    display: flex;
    justify-content: space-between;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 20px 30px;
    margin-bottom: 50px;
}

.metric {
    text-align: center;
}

.metric span {
    display: block;
    font-size: 0.85rem;
    color: #aaa;
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.metric strong {
    font-size: 1.6rem;
    color: var(--primary-yellow);
}

.evidence-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    gap: 20px;
}

.evidence-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 12px;
    border-radius: 10px;
    text-align: center;
    cursor: pointer;
    transition: 0.2s ease;
}

.evidence-card:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

.evidence-card img {
    width: 100%;
    border-radius: 6px;
    margin-bottom: 8px;
    mix-blend-mode: screen;
    /* Enhance dark patches */
}

.evidence-card .meta {
    font-size: 0.8rem;
    color: #ccc;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.evidence-card .score {
    color: var(--primary-yellow);
    font-weight: bold;
}

.result-actions {
    display: flex;
    justify-content: flex-end;
    gap: 20px;
    margin-top: 50px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 30px;
}

/* =========================================
   TEAM SECTION
   ========================================= */
.team-carousel-section {
    max-width: 1000px;
    margin: 0 auto;
    position: relative;
    padding: 0 40px;
    /* Space for navigation arrows */
}

.team-swiper {
    width: 100%;
    padding: 10px 10px 50px 10px;
    /* Space for pagination and shadow clipping */
    margin: -10px -10px 10px -10px;
    overflow: hidden;
    /* Swiper default, but keep it explicit */
}

.team-swiper .swiper-slide {
    display: flex;
    align-items: stretch;
    justify-content: center;
}

.team-card {
    display: flex;
    flex-direction: column;
    background: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 32px;
    transition: transform 0.2s ease, border-color 0.2s;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    width: 100%;
    min-height: 100%;
    /* Important for swiper */
    box-sizing: border-box;
}

.team-card:hover {
    border-color: var(--primary-color);
    /* Remove translate on hover inside Swiper as it might cause clipping or scroll issues depending on overflow settings */
}

.team-image-wrapper {
    flex-shrink: 0;
    margin-bottom: 24px;
    text-align: center;
}

.team-image {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--border-color);
    background-color: #222;
    /* Fallback for transparency */
}

.team-card:hover .team-image {
    border-color: var(--primary-color);
}

.team-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.team-name {
    font-size: 1.6rem;
    color: var(--primary-yellow);
    margin: 0 0 12px 0;
    font-weight: 600;
}

.team-bio {
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.6;
    margin: 0;
    text-align: justify;
    overflow: visible;
}

/* Swiper custom styling for dark theme */
.swiper-pagination-bullet {
    background-color: var(--text-secondary);
    opacity: 0.5;
}

.swiper-pagination-bullet-active {
    background-color: var(--primary-yellow);
    opacity: 1;
}

.swiper-button-next,
.swiper-button-prev {
    color: var(--primary-yellow);
    /* Improve visibility on dark background */
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.swiper-button-next::after,
.swiper-button-prev::after {
    font-size: 24px;
    font-weight: bold;
}

/* Move arrows slightly outside */
.swiper-button-prev {
    left: 0px;
}

.swiper-button-next {
    right: 0px;
}

/* Tablet and larger */
@media (min-width: 768px) {
    .team-card {
        flex-direction: row;
        align-items: center;
        gap: 40px;
        padding: 40px;
    }

    .team-image-wrapper {
        margin-bottom: 0;
    }
}

/* =========================================
   DEEPTECH VISUAL REFINEMENT
   ========================================= */
html {
    scroll-behavior: smooth;
    scroll-padding-top: 96px;
}

body::after {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background:
        radial-gradient(circle at 74% 22%, rgba(252, 191, 55, 0.12), transparent 18%),
        radial-gradient(circle at 12% 82%, rgba(252, 191, 55, 0.08), transparent 20%),
        linear-gradient(115deg, transparent 0 45%, rgba(252, 191, 55, 0.08) 45.2%, transparent 45.7%),
        radial-gradient(circle, rgba(255, 255, 255, 0.16) 0 1px, transparent 1px);
    background-size: auto, auto, auto, 42px 42px;
    opacity: 0.5;
    transform: translateZ(0);
    z-index: 0;
}

#site-header {
    position: sticky;
    top: 0;
    backdrop-filter: blur(16px);
    box-shadow: 0 12px 36px rgba(0, 0, 0, 0.24);
}

#site-header nav a {
    position: relative;
}

#site-header nav a::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -2px;
    height: 2px;
    background: var(--primary-yellow);
    transform: scaleX(0);
    transform-origin: center;
    transition: transform 180ms ease;
}

#site-header nav a:hover::after,
#site-header nav a.active::after {
    transform: scaleX(1);
}

button,
a,
select {
    touch-action: manipulation;
}

button:focus-visible,
a:focus-visible,
select:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid var(--primary-yellow);
    outline-offset: 3px;
}

.section-heading {
    max-width: 820px;
    margin: 0 auto 28px;
    text-align: center;
}

.section-heading h2 {
    margin-bottom: 0;
    font-size: clamp(1.8rem, 3vw, 2.6rem);
    line-height: 1.14;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    color: var(--primary-yellow);
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.12em;
}

.eyebrow::before {
    content: "";
    width: 32px;
    height: 1px;
    background: var(--primary-yellow);
}

.spotlight-grid,
.differentials-grid,
.stats-section,
.capability-grid,
.application-grid {
    display: grid;
    gap: 24px;
}

.spotlight-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin-top: 34px;
}

.spotlight-card,
.product-card,
.feature-item,
.stat-card,
.process-step,
.capability-grid article,
.application-grid article,
.timeline article,
.analysis-card,
.contact-form-block {
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.052), rgba(255, 255, 255, 0.018)),
        rgba(18, 18, 19, 0.78);
    border: 1px solid rgba(252, 191, 55, 0.16);
    border-radius: 8px;
    box-shadow: 0 20px 58px rgba(0, 0, 0, 0.26);
}

.spotlight-card,
.product-card {
    min-height: 280px;
    padding: 28px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    transition: transform 220ms ease, border-color 220ms ease, box-shadow 220ms ease;
}

.spotlight-card:hover,
.product-card:hover,
.feature-item:hover {
    transform: translateY(-6px);
    border-color: rgba(252, 191, 55, 0.55);
    box-shadow: 0 26px 72px rgba(0, 0, 0, 0.34), 0 0 0 1px rgba(252, 191, 55, 0.08);
}

.spotlight-card h2,
.product-card h3 {
    font-size: 1.35rem;
    line-height: 1.22;
}

.spotlight-card p,
.product-card p,
.feature-item p {
    color: var(--text-secondary);
    line-height: 1.65;
}

.spotlight-card .btn-primary,
.product-card .btn-secondary {
    margin-top: auto;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
}

.icon-shell {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-yellow);
    background: rgba(252, 191, 55, 0.1);
    border: 1px solid rgba(252, 191, 55, 0.22);
    margin-bottom: 18px;
}

.feature-band {
    padding: 56px 0 18px;
}

.differentials-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.feature-item {
    padding: 24px;
    transition: transform 220ms ease, border-color 220ms ease;
}

.feature-item i {
    color: var(--primary-yellow);
    margin-bottom: 16px;
    font-size: 1.35rem;
}

.feature-item h3 {
    font-size: 1.08rem;
    margin-bottom: 10px;
}

.stats-section {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    padding: 22px;
    border: 1px solid rgba(252, 191, 55, 0.14);
    background: rgba(0, 0, 0, 0.24);
}

.stat-card {
    padding: 26px 18px;
    text-align: center;
}

.stat-card strong {
    display: block;
    color: var(--primary-yellow);
    font-size: clamp(2rem, 4vw, 3.1rem);
    line-height: 1;
    font-variant-numeric: tabular-nums;
}

.stat-card span {
    display: block;
    margin-top: 10px;
    color: #d7d7d7;
    font-weight: 500;
}

.science-visual,
.map-placeholder {
    position: relative;
    overflow: hidden;
    isolation: isolate;
}

.products-page {
    padding-top: 48px;
}

.products-page-hero {
    max-width: 920px;
    margin-left: auto;
    margin-right: auto;
    text-align: center;
}

.products-page-hero .eyebrow {
    justify-content: center;
}

.products-page-hero .hero-title {
    margin-top: 14px;
    margin-bottom: 18px;
}

.products-page-intro {
    max-width: 820px;
    margin: 0 auto;
    color: var(--text-secondary);
    font-size: 1.08rem;
    line-height: 1.7;
}

.products-catalog {
    padding-top: 8px;
    max-width: 1050px;
    margin-left: auto;
    margin-right: auto;
}

.products-catalog-grid {
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.catalog-product-card {
    width: 100%;
    min-height: 0;
    padding: 26px;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 30px;
    overflow: hidden;
}

.product-image-trigger {
    appearance: none;
    border: 1px solid rgba(252, 191, 55, 0.14);
    background: rgba(0, 0, 0, 0.34);
    border-radius: 8px;
    margin: 0;
    padding: 14px;
    cursor: pointer;
    flex: 0 0 320px;
    width: 320px;
    height: 220px;
    max-width: 100%;
    overflow: hidden;
    transition: border-color 220ms ease, filter 220ms ease, box-shadow 220ms ease;
}

.product-image-trigger:hover,
.product-image-trigger:focus-visible {
    border-color: rgba(252, 191, 55, 0.42);
    filter: saturate(1.04) brightness(1.04);
    box-shadow: 0 16px 38px rgba(0, 0, 0, 0.22);
}

.product-image-trigger:focus-visible {
    outline: 2px solid rgba(252, 191, 55, 0.72);
    outline-offset: 4px;
}

.product-image-trigger:hover .product-photo,
.product-image-trigger:focus-visible .product-photo {
    transform: scale(1.025);
}

.product-photo {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    border-radius: 4px;
    margin: 0;
    transition: transform 220ms ease;
}

.catalog-product-content {
    flex: 1 1 auto;
    min-width: 0;
}

.catalog-product-content h3 {
    margin-bottom: 12px;
}

.catalog-product-content p {
    max-width: 620px;
    margin-bottom: 0;
    text-align: justify;
}

.catalog-product-card:hover {
    transform: none;
}

.js-enabled .catalog-product-card,
.js-enabled .catalog-product-card.is-visible {
    transform: none;
}

.product-lightbox {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 28px;
    background: rgba(0, 0, 0, 0.82);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.product-lightbox.is-open {
    display: flex;
}

.product-lightbox-dialog {
    position: relative;
    width: min(1080px, 94vw);
    height: min(780px, 86vh);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 28px;
    border: 1px solid rgba(252, 191, 55, 0.18);
    border-radius: 10px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.045), rgba(255, 255, 255, 0.012)),
        rgba(12, 12, 13, 0.92);
    box-shadow: 0 30px 90px rgba(0, 0, 0, 0.55);
}

.product-lightbox-image {
    display: block;
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
}

.product-lightbox-close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(252, 191, 55, 0.22);
    border-radius: 8px;
    color: var(--primary-yellow);
    background: rgba(0, 0, 0, 0.5);
    cursor: pointer;
    transition: border-color 180ms ease, background 180ms ease;
}

.product-lightbox-close:hover,
.product-lightbox-close:focus-visible {
    border-color: rgba(252, 191, 55, 0.58);
    background: rgba(252, 191, 55, 0.1);
}

.science-visual::before {
    content: "";
    position: absolute;
    inset: 18%;
    border: 2px solid rgba(252, 191, 55, 0.42);
    border-radius: 50%;
    filter: blur(0.2px);
}

.split-section {
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    gap: 40px;
    align-items: center;
    padding: 26px 0;
}

.science-visual {
    min-height: 420px;
    border-radius: 8px;
    background:
        linear-gradient(120deg, rgba(252, 191, 55, 0.2), transparent 42%),
        radial-gradient(circle at 72% 24%, rgba(255, 255, 255, 0.12), transparent 14%),
        linear-gradient(145deg, #171717, #070707);
    border: 1px solid rgba(252, 191, 55, 0.18);
    box-shadow: inset 0 0 80px rgba(252, 191, 55, 0.08), 0 22px 70px rgba(0, 0, 0, 0.34);
}

.science-visual::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, transparent 0 47%, rgba(252, 191, 55, 0.14) 47.5% 48%, transparent 48.5%),
        linear-gradient(0deg, transparent 0 47%, rgba(252, 191, 55, 0.1) 47.5% 48%, transparent 48.5%);
    background-size: 72px 72px;
}

.check-list {
    list-style: none;
    padding: 0;
    margin: 24px 0 0;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px 20px;
}

.check-list li {
    color: #e7e7e7;
    display: flex;
    align-items: center;
    gap: 10px;
}

.check-list li::before {
    content: "\f00c";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    color: var(--primary-yellow);
}

.ris-product-intro {
    max-width: 860px;
    margin-left: auto;
    margin-right: auto;
    text-align: center;
}

.ris-product-intro p {
    color: var(--text-secondary);
    font-size: 1.08rem;
    line-height: 1.75;
}

.process-flow {
    display: grid;
    grid-template-columns: 1fr auto 1fr auto 1fr auto 1fr;
    gap: 14px;
    align-items: center;
}

.process-step {
    padding: 24px 16px;
    text-align: center;
}

.process-step span {
    width: 52px;
    height: 52px;
    margin: 0 auto 14px;
    display: grid;
    place-items: center;
    color: var(--primary-yellow);
    border: 1px solid rgba(252, 191, 55, 0.25);
    border-radius: 8px;
    background: rgba(252, 191, 55, 0.08);
}

.process-step h3 {
    font-size: 1rem;
    margin-bottom: 0;
}

.process-arrow {
    color: var(--primary-yellow);
}

.capability-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.capability-grid article,
.application-grid article {
    min-height: 94px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    color: #eeeeee;
    font-weight: 600;
}

.capability-grid i {
    color: var(--primary-yellow);
}

.application-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.timeline {
    position: relative;
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 16px;
}

.timeline::before {
    content: "";
    position: absolute;
    left: 8%;
    right: 8%;
    top: 28px;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(252, 191, 55, 0.8), transparent);
}

.timeline article {
    position: relative;
    min-height: 150px;
    padding: 54px 16px 18px;
}

.timeline article::before {
    content: "";
    position: absolute;
    top: 20px;
    left: 18px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--primary-yellow);
    box-shadow: 0 0 0 8px rgba(252, 191, 55, 0.1);
}

.timeline strong {
    display: block;
    color: var(--primary-yellow);
    margin-bottom: 8px;
}

.timeline span {
    color: var(--text-secondary);
    font-size: 0.92rem;
    line-height: 1.45;
}

.contact-container {
    align-items: start;
}

.contact-form-block {
    padding: 30px;
}

.address-card span {
    color: var(--text-secondary);
    display: block;
    line-height: 1.55;
}

.map-placeholder {
    min-height: 280px;
    margin-top: 28px;
    border-radius: 8px;
    border: 1px solid rgba(252, 191, 55, 0.2);
    background: #111;
    box-shadow: 0 18px 44px rgba(0, 0, 0, 0.28);
}

.map-placeholder iframe {
    width: 100%;
    height: 100%;
    min-height: 280px;
    display: block;
    border: 0;
    filter: grayscale(0.18) contrast(0.95) brightness(0.9);
}

.map-open-link {
    position: absolute;
    left: 18px;
    bottom: 16px;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 44px;
    padding: 0 14px;
    border-radius: 8px;
    border: 1px solid rgba(252, 191, 55, 0.28);
    background: rgba(9, 9, 10, 0.84);
    color: #fff;
    font-weight: 600;
    text-decoration: none;
    backdrop-filter: blur(10px);
}

.map-open-link:hover {
    color: var(--primary-yellow);
    border-color: rgba(252, 191, 55, 0.52);
}

.team-carousel-section {
    max-width: 1180px;
}

.team-card {
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.018)),
        rgba(18, 18, 19, 0.86);
    border-color: rgba(252, 191, 55, 0.16);
    min-height: auto;
}

.team-image {
    width: 220px;
    height: 220px;
    border-radius: 8px;
    border-color: rgba(252, 191, 55, 0.24);
}

.team-name {
    margin-bottom: 4px;
}

.team-role {
    display: block;
    color: #d0d0d0;
    font-size: 0.95rem;
    margin-bottom: 18px;
}

.team-bio {
    display: block;
    overflow: visible;
    -webkit-line-clamp: unset;
    -webkit-box-orient: initial;
    margin-bottom: 0;
    max-width: 78ch;
}

.bio-modal {
    position: fixed;
    inset: 0;
    z-index: 5000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(0, 0, 0, 0.68);
    backdrop-filter: blur(10px);
}

.bio-modal[aria-hidden="false"] {
    display: flex;
}

.bio-modal-panel {
    width: min(760px, 100%);
    max-height: min(720px, 88vh);
    overflow: auto;
    position: relative;
    padding: 34px;
    border-radius: 8px;
    background: #121213;
    border: 1px solid rgba(252, 191, 55, 0.28);
    box-shadow: 0 30px 90px rgba(0, 0, 0, 0.55);
}

.bio-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid rgba(252, 191, 55, 0.2);
    background: rgba(255, 255, 255, 0.04);
    color: #fff;
    cursor: pointer;
}

.bio-modal-text {
    color: var(--text-secondary);
    line-height: 1.75;
    text-align: justify;
}

.modal-open {
    overflow: hidden;
}

#site-footer {
    background:
        linear-gradient(180deg, rgba(18, 18, 19, 0.96), #09090a);
    border-top: 1px solid rgba(252, 191, 55, 0.16);
    padding: 44px 16px 24px;
}

.footer-grid {
    width: min(1120px, 100%);
    margin: 0 auto 26px;
    display: grid;
    grid-template-columns: 1.4fr 1fr 1.2fr 1fr;
    gap: 32px;
    text-align: left;
}

.footer-grid h3 {
    color: var(--primary-yellow);
    font-size: 0.95rem;
    text-transform: uppercase;
    margin-bottom: 14px;
}

.footer-grid a,
.footer-grid span,
.footer-grid p {
    display: block;
    color: var(--text-secondary);
    margin-bottom: 10px;
    line-height: 1.5;
}

.footer-brand img {
    height: 44px;
    width: auto;
    margin-bottom: 14px;
}

.footer-legal {
    width: min(1120px, 100%);
    margin: 0 auto;
    padding-top: 18px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.js-enabled .reveal-on-scroll,
.js-enabled .spotlight-card,
.js-enabled .product-card {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity 260ms ease var(--reveal-delay, 0ms), transform 260ms ease var(--reveal-delay, 0ms);
}

.js-enabled .reveal-on-scroll.is-visible,
.js-enabled .spotlight-card.is-visible,
.js-enabled .product-card.is-visible {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 1024px) {
    .spotlight-grid,
    .split-section,
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }

    .catalog-product-card {
        gap: 24px;
    }

    .product-image-trigger {
        flex-basis: 280px;
        width: 280px;
        height: 200px;
    }

    .differentials-grid,
    .stats-section,
    .capability-grid,
    .timeline {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .timeline::before {
        display: none;
    }

    .process-flow {
        grid-template-columns: 1fr;
    }

    .process-arrow {
        transform: rotate(90deg);
        justify-self: center;
    }
}

@media (max-width: 700px) {
    #site-main {
        padding-left: 16px;
        padding-right: 16px;
    }

    .spotlight-grid,
    .split-section,
    .differentials-grid,
    .stats-section,
    .capability-grid,
    .application-grid,
    .timeline,
    .footer-grid,
    .check-list {
        grid-template-columns: 1fr;
    }

    .products-page {
        padding-top: 28px;
    }

    .products-catalog {
        max-width: 100%;
    }

    .catalog-product-card {
        flex-direction: column;
        align-items: stretch;
        gap: 20px;
    }

    .product-image-trigger {
        flex: none;
        width: 100%;
        height: 230px;
        align-self: center;
    }

    .product-lightbox {
        padding: 16px;
    }

    .product-lightbox-dialog {
        width: 100%;
        height: min(620px, 82vh);
        padding: 18px;
    }

    .catalog-product-content p {
        max-width: none;
    }

    .spotlight-card,
    .product-card,
    .contact-form-block,
    .bio-modal-panel {
        padding: 22px;
    }

    .science-visual {
        min-height: 280px;
    }

    .stats-section {
        padding: 14px;
    }

    .analysis-summary,
    .metrics-panel,
    .result-actions,
    .upload-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .analysis-classification {
        max-width: none;
        text-align: center;
    }

    .team-carousel-section {
        padding: 0 22px;
    }

    .team-image {
        width: 180px;
        height: 180px;
    }
}

/* =========================================
   RIS TOOL-FIRST PAGE
   ========================================= */
.ris-tool-page {
    max-width: 1280px !important;
    padding-top: 18px !important;
}

.ris-tool-page #site-main section,
.ris-tool-page section {
    margin-bottom: 32px;
}

.ris-workbench {
    min-height: calc(100dvh - 96px);
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}

.ris-tool-brand {
    margin: 0 0 14px 0;
}

.ris-brand-hero {
    height: 116px;
    border-radius: 8px;
    background-size: min(520px, 80vw) auto;
    box-shadow: 0 16px 46px rgba(0, 0, 0, 0.24);
}

.ris-tool-page .hero-section::after {
    display: none;
}

.ris-tool-page .ris-hero {
    margin: 0 0 18px;
}

.ris-tool-page .ris-hero h1 {
    font-size: clamp(2rem, 4vw, 3.2rem);
    margin-bottom: 8px;
}

.ris-tool-page .ris-hero p {
    font-size: clamp(1rem, 1.5vw, 1.22rem);
}

.ris-tool-page .ris-analysis {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    width: min(1060px, 100%);
    margin: 0 auto 24px;
}

.ris-tool-page .analysis-card {
    max-width: none;
    min-height: clamp(430px, 52vh, 610px);
    padding: clamp(24px, 4vw, 44px);
    border-color: rgba(252, 191, 55, 0.36);
    background:
        radial-gradient(circle at 50% 0%, rgba(252, 191, 55, 0.13), transparent 34%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.018)),
        rgba(13, 13, 14, 0.92);
    box-shadow:
        0 28px 88px rgba(0, 0, 0, 0.42),
        0 0 0 1px rgba(252, 191, 55, 0.08),
        0 0 46px rgba(252, 191, 55, 0.09);
}

.ris-tool-page .analysis-header {
    margin-bottom: 22px;
}

.ris-tool-page .analysis-header h2 {
    margin-bottom: 6px;
    font-size: clamp(1.35rem, 2.4vw, 2rem);
}

.ris-tool-page .analysis-header p {
    margin: 0;
    color: var(--text-secondary);
}

.ris-tool-page .pipeline-visualizer {
    display: none !important;
}

.ris-tool-page .upload-zone {
    min-height: clamp(260px, 34vh, 420px);
    padding: clamp(28px, 5vw, 54px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border: 1px dashed rgba(252, 191, 55, 0.58);
    background:
        radial-gradient(circle at 50% 28%, rgba(252, 191, 55, 0.13), transparent 34%),
        linear-gradient(135deg, rgba(252, 191, 55, 0.07), rgba(255, 255, 255, 0.02)),
        rgba(0, 0, 0, 0.42);
    box-shadow: inset 0 0 42px rgba(252, 191, 55, 0.07);
    animation: risUploadPulse 2.8s ease-in-out infinite;
}

.upload-icon {
    font-size: clamp(3rem, 7vw, 5.4rem);
    color: var(--primary-yellow);
    margin-bottom: 20px;
    filter: drop-shadow(0 0 18px rgba(252, 191, 55, 0.24));
}

.ris-tool-page .upload-zone p {
    font-size: clamp(1.35rem, 2.6vw, 2rem);
    font-weight: 700;
}

.ris-tool-page .upload-zone small {
    font-size: 1rem;
    margin-bottom: 30px;
}

.ris-tool-page .upload-actions .btn-primary {
    min-height: 52px;
    padding: 15px 28px;
    font-size: 1rem;
    box-shadow: 0 16px 38px rgba(252, 191, 55, 0.18);
}

.ris-preview {
    margin-top: 0 !important;
    display: grid;
    gap: 18px;
}

.ris-preview img {
    width: 100%;
    max-height: 430px;
    object-fit: contain;
    border: 1px solid rgba(252, 191, 55, 0.28) !important;
    border-radius: 8px !important;
    background: rgba(0, 0, 0, 0.45);
}

.layer-controls {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin-top: 0 !important;
}

.layer-btn {
    min-height: 40px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: rgba(255, 255, 255, 0.035);
    color: #d8d8d8;
    border-radius: 999px;
    padding: 8px 14px;
    cursor: pointer;
}

.layer-btn.active,
.layer-btn:hover {
    color: #000;
    background: var(--primary-yellow);
    border-color: var(--primary-yellow);
}

.preview-actions {
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

.ris-processing {
    width: min(680px, 100%);
    margin: 18px auto 0;
    padding: 24px !important;
    border: 1px solid rgba(252, 191, 55, 0.2);
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.36);
}

.ris-processing .fa-circle-notch {
    font-size: 2rem;
}

.processing-bar {
    height: 8px;
    margin-top: 18px;
    border-radius: 999px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.1);
}

.processing-fill {
    width: 0%;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #9b6a0d, var(--primary-yellow));
    transition: width 280ms ease;
}

.rejection-card {
    border: 1px solid #ef4444;
    background: rgba(239, 68, 68, 0.1);
    padding: 1rem;
    border-radius: 8px;
    margin-top: 1rem;
}

.rejection-card h4 {
    color: #ef4444;
    margin: 0;
}

.rejection-card p {
    margin: 0.5rem 0 0;
}

.ris-results {
    width: 100%;
}

.results-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 24px;
    align-items: start;
}

.results-main,
.interpretation-panel,
.ris-about-copy,
.parameter-grid article {
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.048), rgba(255, 255, 255, 0.016)),
        rgba(18, 18, 19, 0.84);
    border: 1px solid rgba(252, 191, 55, 0.16);
    border-radius: 8px;
    box-shadow: 0 20px 58px rgba(0, 0, 0, 0.25);
}

.results-main {
    padding: 24px;
}

.interpretation-panel {
    position: sticky;
    top: 96px;
    padding: 22px;
}

.interpretation-panel h2 {
    font-size: 1.28rem;
    margin-bottom: 18px;
    color: var(--primary-yellow);
}

.interpretation-item {
    display: grid;
    grid-template-columns: 22px 1fr;
    gap: 12px;
    padding: 13px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.interpretation-item:first-of-type {
    border-top: 0;
}

.interpretation-item p {
    margin: 0;
    color: var(--text-secondary);
    line-height: 1.45;
}

.interpretation-item strong {
    color: #fff;
}

.interpretation-item.good i {
    color: #22c55e;
}

.interpretation-item.warn i {
    color: #f59e0b;
}

.interpretation-item.danger i {
    color: #ef4444;
}

.confidence-block {
    margin: -8px 0 30px;
}

.confidence-block > div:first-child {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    color: #aaa;
    margin-bottom: 8px;
}

.evidence-group {
    margin-bottom: 34px;
}

.evidence-group h4 {
    margin-bottom: 16px;
    color: #cfcfcf;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 8px;
}

.zoom-context {
    margin-top: 2rem;
    display: flex;
    gap: 1.5rem;
    align-items: center;
    background: rgba(255, 255, 255, 0.02);
    padding: 24px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.zoom-context img {
    width: 140px;
    height: 140px;
    object-fit: cover;
    border: 2px solid var(--primary-yellow);
    border-radius: 8px;
}

#meta-type {
    font-weight: bold;
    font-size: 1.4rem;
    color: var(--primary-yellow);
    margin-bottom: 8px;
}

#meta-conf {
    color: #ccc;
    font-size: 1.1rem;
}

.ris-about-panel {
    max-width: 980px;
    margin-left: auto;
    margin-right: auto;
}

.ris-about-copy {
    padding: clamp(24px, 4vw, 42px);
}

.ris-about-copy p {
    color: #d2d2d2;
    line-height: 1.78;
    font-size: 1.06rem;
    margin: 0 0 18px;
}

.ris-about-copy p:last-child {
    margin-bottom: 0;
}

.parameter-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.parameter-grid article {
    padding: 22px;
    min-height: 210px;
}

.parameter-grid i {
    color: var(--primary-yellow);
    font-size: 1.35rem;
    margin-bottom: 16px;
}

.parameter-grid h3 {
    font-size: 1.05rem;
    margin-bottom: 10px;
}

.parameter-grid p {
    color: var(--text-secondary);
    line-height: 1.56;
    margin: 0;
    font-size: 0.95rem;
}

@keyframes risUploadPulse {
    0%,
    100% {
        border-color: rgba(252, 191, 55, 0.42);
        box-shadow: inset 0 0 38px rgba(252, 191, 55, 0.06), 0 0 0 rgba(252, 191, 55, 0);
    }

    50% {
        border-color: rgba(252, 191, 55, 0.72);
        box-shadow: inset 0 0 52px rgba(252, 191, 55, 0.1), 0 0 34px rgba(252, 191, 55, 0.08);
    }
}

@media (max-width: 1024px) {
    .results-layout,
    .parameter-grid {
        grid-template-columns: 1fr 1fr;
    }

    .interpretation-panel {
        position: static;
    }
}

@media (max-width: 700px) {
    .ris-brand-hero {
        height: 84px;
    }

    .ris-workbench {
        min-height: auto;
    }

    .ris-tool-page .analysis-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 14px;
    }

    .ris-tool-page .upload-actions,
    .preview-actions,
    .results-layout,
    .parameter-grid {
        grid-template-columns: 1fr;
    }

    .results-layout,
    .parameter-grid {
        display: grid;
    }

    .ris-tool-page .upload-actions {
        flex-direction: column;
        width: 100%;
    }

    .ris-tool-page .upload-actions button {
        width: 100%;
    }
}

@media (prefers-reduced-motion: reduce) {
    .ris-tool-page .upload-zone {
        animation: none;
    }
}
