/* ========================================
   IkanKita – Global Stylesheet
   Design: Dark ocean theme, glassmorphism
   ======================================== */

/* ---- Reset & Base ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --navy: #060f1e;
    --navy-2: #0a1628;
    --navy-3: #0d1f38;
    --navy-4: #112347;
    --teal: #14b8a6;
    --teal-2: #0d9488;
    --cyan: #06b6d4;
    --cyan-2: #0891b2;
    --emerald: #10b981;
    --emerald-2: #059669;
    --red: #ef4444;
    --orange: #f97316;
    --purple: #a855f7;
    --pink: #ec4899;
    --yellow: #eab308;
    --text: #f1f5f9;
    --text-muted: #94a3b8;
    --text-dim: #64748b;
    --glass: rgba(255,255,255,0.05);
    --glass-border: rgba(255,255,255,0.1);
    --shadow: 0 25px 50px rgba(0,0,0,0.5);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --radius: 16px;
    --radius-sm: 10px;
    --radius-lg: 24px;
}

html { scroll-behavior: smooth; }

body {
    font-family: 'Inter', system-ui, sans-serif;
    background-color: var(--navy);
    color: var(--text);
    line-height: 1.6;
    overflow-x: hidden;
}

.hidden { display: none !important; }

/* ========================================
   NAVBAR
======================================== */
.navbar {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 1000;
    padding: 0 24px;
    transition: var(--transition);
    background: transparent;
}

.navbar.scrolled, .navbar.dark {
    background: rgba(6, 15, 30, 0.9);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 70px;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.brand-icon {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.brand-icon.small { width: 28px; height: 28px; }
.brand-icon svg { width: 100%; height: 100%; }

.brand-name {
    font-size: 1.3rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--teal), var(--cyan));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.5px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-link {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    padding: 8px 16px;
    border-radius: 8px;
    transition: var(--transition);
}

.nav-link:hover { color: var(--text); background: var(--glass); }

.btn-nav-cta {
    background: linear-gradient(135deg, var(--teal), var(--cyan));
    color: #fff;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    padding: 10px 20px;
    border-radius: 10px;
    transition: var(--transition);
    margin-left: 8px;
}

.btn-nav-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(20, 184, 166, 0.4);
}

.btn-ghost-sm {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    padding: 8px 16px;
    border-radius: 8px;
    border: 1px solid var(--glass-border);
    transition: var(--transition);
}

.btn-ghost-sm svg { width: 18px; height: 18px; }
.btn-ghost-sm:hover { color: var(--text); background: var(--glass); }

.nav-hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}

.nav-hamburger span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text-muted);
    border-radius: 2px;
    transition: var(--transition);
}

/* ========================================
   BUTTONS
======================================== */
.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: linear-gradient(135deg, var(--teal), var(--cyan));
    color: #fff;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 600;
    padding: 13px 26px;
    border-radius: 12px;
    border: none;
    cursor: pointer;
    transition: var(--transition);
}

.btn-primary svg { width: 18px; height: 18px; flex-shrink: 0; }
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 35px rgba(20, 184, 166, 0.45);
}
.btn-primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}
.btn-primary.large { font-size: 1.05rem; padding: 16px 32px; border-radius: 14px; }

.btn-ghost {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: transparent;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 600;
    padding: 13px 26px;
    border-radius: 12px;
    border: 1px solid var(--glass-border);
    cursor: pointer;
    transition: var(--transition);
}

.btn-ghost svg { width: 18px; height: 18px; }
.btn-ghost:hover { color: var(--text); background: var(--glass); border-color: rgba(255,255,255,0.2); }

.btn-outline {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: transparent;
    color: var(--teal);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 600;
    padding: 13px 26px;
    border-radius: 12px;
    border: 2px solid var(--teal);
    cursor: pointer;
    transition: var(--transition);
}

.btn-outline svg { width: 18px; height: 18px; }
.btn-outline:hover {
    background: rgba(20, 184, 166, 0.1);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(20, 184, 166, 0.2);
}
.btn-outline.large { font-size: 1.05rem; padding: 16px 32px; border-radius: 14px; }

.full-width { width: 100%; justify-content: center; }

/* ========================================
   HERO SECTION
======================================== */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding-top: 70px;
}

.hero-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
    background: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(20, 184, 166, 0.15) 0%, transparent 70%),
                radial-gradient(ellipse 60% 40% at 90% 50%, rgba(6, 182, 212, 0.1) 0%, transparent 60%),
                linear-gradient(180deg, var(--navy) 0%, var(--navy-2) 100%);
}

.wave {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 200px;
    background: transparent;
}

.wave-1 {
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 200'%3E%3Cpath fill='rgba(20,184,166,0.05)' d='M0,100L60,90C120,80,240,60,360,70C480,80,600,120,720,120C840,120,960,80,1080,70C1200,60,1320,80,1380,90L1440,100L1440,200L0,200Z'/%3E%3C/svg%3E") no-repeat bottom center;
    background-size: 200% 100%;
    animation: waveAnim 8s ease-in-out infinite;
}

.wave-2 {
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 200'%3E%3Cpath fill='rgba(6,182,212,0.07)' d='M0,120L80,110C160,100,320,80,480,90C640,100,800,130,960,130C1120,130,1280,100,1360,85L1440,70L1440,200L0,200Z'/%3E%3C/svg%3E") no-repeat bottom center;
    background-size: 200% 100%;
    animation: waveAnim 10s ease-in-out infinite reverse;
}

.wave-3 {
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 200'%3E%3Cpath fill='rgba(10,22,40,0.8)' d='M0,150L120,140C240,130,480,110,720,115C960,120,1200,140,1320,145L1440,150L1440,200L0,200Z'/%3E%3C/svg%3E") no-repeat bottom center;
    background-size: 200% 100%;
    animation: waveAnim 12s ease-in-out infinite;
}

@keyframes waveAnim {
    0%, 100% { background-position: 0% 100%; }
    50% { background-position: 100% 100%; }
}

.hero-container {
    position: relative;
    z-index: 1;
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 24px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(20, 184, 166, 0.1);
    border: 1px solid rgba(20, 184, 166, 0.3);
    color: var(--teal);
    font-size: 0.82rem;
    font-weight: 600;
    padding: 6px 14px;
    border-radius: 100px;
    margin-bottom: 24px;
    letter-spacing: 0.5px;
}

.badge-dot {
    width: 7px;
    height: 7px;
    background: var(--teal);
    border-radius: 50%;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(0.7); }
}

.hero-title {
    font-size: clamp(2.5rem, 5vw, 3.8rem);
    font-weight: 900;
    line-height: 1.1;
    letter-spacing: -2px;
    margin-bottom: 24px;
}

.gradient-text {
    background: linear-gradient(135deg, var(--teal) 0%, var(--cyan) 50%, #818cf8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-desc {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 36px;
    max-width: 500px;
    line-height: 1.7;
}

.hero-actions {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 48px;
}

.hero-stats {
    display: flex;
    align-items: center;
    gap: 32px;
}

.stat-item {
    display: flex;
    flex-direction: column;
}

.stat-number {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text);
    letter-spacing: -1px;
    line-height: 1;
}

.stat-suffix {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--teal);
}

.stat-label {
    font-size: 0.78rem;
    color: var(--text-dim);
    margin-top: 4px;
    font-weight: 500;
}

.stat-divider {
    width: 1px;
    height: 40px;
    background: var(--glass-border);
}

/* Phone Mockup */
.hero-visual {
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.phone-mockup {
    position: relative;
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

.phone-frame {
    width: 280px;
    background: var(--navy-3);
    border-radius: 40px;
    border: 2px solid rgba(255,255,255,0.12);
    padding: 12px;
    box-shadow: 0 40px 80px rgba(0,0,0,0.6), inset 0 1px 0 rgba(255,255,255,0.1);
    position: relative;
    z-index: 2;
}

.phone-screen {
    border-radius: 30px;
    overflow: hidden;
    background: var(--navy-2);
    aspect-ratio: 9/16;
    max-height: 480px;
}

.mock-app {
    height: 100%;
    display: flex;
    flex-direction: column;
    padding: 16px;
    gap: 12px;
}

.mock-header {
    display: flex;
    gap: 6px;
    align-items: center;
}

.mock-dot { width: 10px; height: 10px; border-radius: 50%; }
.mock-dot.red { background: #ef4444; }
.mock-dot.yellow { background: #eab308; }
.mock-dot.green { background: #22c55e; }

.mock-camera {
    flex: 1;
    background: var(--navy-4);
    border-radius: 20px;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mock-fish-icon { font-size: 3.5rem; position: relative; z-index: 2; }

.scan-line {
    position: absolute;
    left: 0; right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--teal), transparent);
    animation: scan 2.5s ease-in-out infinite;
    z-index: 3;
}

@keyframes scan {
    0% { top: 20%; opacity: 0; }
    10% { opacity: 1; }
    90% { opacity: 1; }
    100% { top: 80%; opacity: 0; }
}

.corner { position: absolute; width: 20px; height: 20px; z-index: 4; }
.corner.tl { top: 15px; left: 15px; border-top: 3px solid var(--teal); border-left: 3px solid var(--teal); border-radius: 3px 0 0 0; }
.corner.tr { top: 15px; right: 15px; border-top: 3px solid var(--teal); border-right: 3px solid var(--teal); border-radius: 0 3px 0 0; }
.corner.bl { bottom: 15px; left: 15px; border-bottom: 3px solid var(--teal); border-left: 3px solid var(--teal); border-radius: 0 0 0 3px; }
.corner.br { bottom: 15px; right: 15px; border-bottom: 3px solid var(--teal); border-right: 3px solid var(--teal); border-radius: 0 0 3px 0; }

.mock-result {
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.mock-result-badge {
    font-size: 0.85rem;
    font-weight: 700;
    padding: 6px 14px;
    border-radius: 100px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.mock-result-badge.fresh {
    background: rgba(16, 185, 129, 0.15);
    color: var(--emerald);
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.mock-confidence {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.75rem;
    color: var(--text-muted);
}

.conf-bar { flex: 1; height: 6px; background: rgba(255,255,255,0.1); border-radius: 3px; overflow: hidden; }
.conf-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--teal), var(--cyan));
    border-radius: 3px;
    transition: width 2s ease;
}

.phone-glow {
    position: absolute;
    bottom: -30px;
    left: 50%;
    transform: translateX(-50%);
    width: 200px;
    height: 60px;
    background: rgba(20, 184, 166, 0.3);
    border-radius: 50%;
    filter: blur(30px);
}

/* ========================================
   SECTIONS
======================================== */
.section-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 100px 24px;
}

.section-header {
    text-align: center;
    margin-bottom: 64px;
}

.section-tag {
    display: inline-block;
    background: rgba(20, 184, 166, 0.1);
    border: 1px solid rgba(20, 184, 166, 0.3);
    color: var(--teal);
    font-size: 0.8rem;
    font-weight: 600;
    padding: 5px 14px;
    border-radius: 100px;
    margin-bottom: 16px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.section-title {
    font-size: clamp(1.8rem, 3.5vw, 2.8rem);
    font-weight: 800;
    letter-spacing: -1px;
    margin-bottom: 16px;
    line-height: 1.15;
}

.section-desc {
    color: var(--text-muted);
    font-size: 1rem;
    max-width: 560px;
    margin: 0 auto;
}

/* ========================================
   FEATURES SECTION
======================================== */
.features {
    background: linear-gradient(180deg, var(--navy) 0%, var(--navy-2) 100%);
    position: relative;
}

.features::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 50% 50% at 50% 50%, rgba(20, 184, 166, 0.05) 0%, transparent 70%);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.feature-card {
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius);
    padding: 28px;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    inset: 0;
    opacity: 0;
    background: linear-gradient(135deg, rgba(20, 184, 166, 0.08) 0%, transparent 60%);
    transition: var(--transition);
}

.feature-card:hover { transform: translateY(-4px); border-color: rgba(255,255,255,0.2); }
.feature-card:hover::before { opacity: 1; }

.feature-card.featured {
    grid-column: span 1;
    border-color: rgba(20, 184, 166, 0.3);
    background: rgba(20, 184, 166, 0.05);
}

.feature-icon-wrap {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 18px;
}

.feature-icon-wrap svg { width: 24px; height: 24px; }
.feature-icon-wrap.teal { background: rgba(20, 184, 166, 0.15); color: var(--teal); }
.feature-icon-wrap.cyan { background: rgba(6, 182, 212, 0.15); color: var(--cyan); }
.feature-icon-wrap.emerald { background: rgba(16, 185, 129, 0.15); color: var(--emerald); }
.feature-icon-wrap.purple { background: rgba(168, 85, 247, 0.15); color: var(--purple); }
.feature-icon-wrap.orange { background: rgba(249, 115, 22, 0.15); color: var(--orange); }
.feature-icon-wrap.pink { background: rgba(236, 72, 153, 0.15); color: var(--pink); }

.feature-card h3 { font-size: 1.05rem; font-weight: 700; margin-bottom: 10px; }
.feature-card p { font-size: 0.9rem; color: var(--text-muted); line-height: 1.6; }

.feature-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--teal);
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    margin-top: 16px;
    transition: var(--transition);
}

.feature-link:hover { gap: 10px; }
.feature-link span { transition: var(--transition); }

/* ========================================
   HOW IT WORKS
======================================== */
.how-it-works {
    background: var(--navy-2);
}

.steps-container {
    display: flex;
    align-items: center;
    gap: 20px;
    justify-content: center;
}

.step-card {
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 36px 28px;
    text-align: center;
    flex: 1;
    max-width: 300px;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.step-card::after {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--teal), var(--cyan));
    opacity: 0;
    transition: var(--transition);
}

.step-card:hover { transform: translateY(-6px); border-color: rgba(255,255,255,0.2); }
.step-card:hover::after { opacity: 1; }

.step-number {
    font-size: 4rem;
    font-weight: 900;
    color: rgba(255,255,255,0.04);
    position: absolute;
    top: 10px; right: 20px;
    line-height: 1;
    letter-spacing: -4px;
    font-variant-numeric: tabular-nums;
}

.step-icon {
    width: 64px;
    height: 64px;
    border-radius: 18px;
    background: linear-gradient(135deg, rgba(20, 184, 166, 0.2), rgba(6, 182, 212, 0.2));
    border: 1px solid rgba(20, 184, 166, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    color: var(--teal);
}

.step-icon svg { width: 28px; height: 28px; }
.step-card h3 { font-size: 1.05rem; font-weight: 700; margin-bottom: 10px; }
.step-card p { font-size: 0.88rem; color: var(--text-muted); line-height: 1.6; }

.step-arrow {
    color: rgba(255,255,255,0.2);
    flex-shrink: 0;
}
.step-arrow svg { width: 32px; height: 32px; }

/* ========================================
   ACCURACY SECTION
======================================== */
.accuracy-section {
    background: var(--navy);
    position: relative;
    overflow: hidden;
}

.accuracy-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 60% 60% at 80% 50%, rgba(20, 184, 166, 0.08) 0%, transparent 70%);
}

.accuracy-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.accuracy-content .section-title { text-align: left; }
.accuracy-content .section-tag { text-align: left; }
.accuracy-content p { color: var(--text-muted); margin-bottom: 36px; }

.metrics-list { display: flex; flex-direction: column; gap: 20px; }

.metric-row {
    display: flex;
    align-items: center;
    gap: 16px;
}

.metric-name {
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--text);
    min-width: 140px;
}

.metric-bar-wrap {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 12px;
}

.metric-bar {
    flex: 1;
    height: 8px;
    background: rgba(255,255,255,0.08);
    border-radius: 4px;
    overflow: hidden;
}

.metric-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--teal), var(--cyan));
    border-radius: 4px;
    transition: width 1.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.metric-value {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--teal);
    min-width: 55px;
    text-align: right;
}

/* Accuracy Card */
.accuracy-card {
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 36px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
    position: relative;
    overflow: hidden;
}

.accuracy-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 80% 80% at 50% 0%, rgba(20, 184, 166, 0.08) 0%, transparent 60%);
}

.acc-ring-wrap {
    position: relative;
    width: 160px;
    height: 160px;
}

.acc-ring { width: 100%; height: 100%; }

.acc-ring-text {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.acc-ring-number { font-size: 2.2rem; font-weight: 900; color: var(--text); letter-spacing: -2px; }
.acc-ring-pct { font-size: 1rem; font-weight: 700; color: var(--teal); margin-top: -8px; }
.acc-ring-label { font-size: 0.72rem; color: var(--text-dim); margin-top: 2px; font-weight: 500; }

.acc-info {
    display: flex;
    gap: 16px;
}

.acc-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.82rem;
    font-weight: 600;
    padding: 8px 14px;
    border-radius: 100px;
}

.fresh-badge {
    background: rgba(16, 185, 129, 0.1);
    color: var(--emerald);
    border: 1px solid rgba(16, 185, 129, 0.25);
}

.notfresh-badge {
    background: rgba(239, 68, 68, 0.1);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.25);
}

.acc-badge-dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.acc-caption { font-size: 0.82rem; color: var(--text-dim); text-align: center; line-height: 1.6; position: relative; z-index: 1; }
.acc-caption strong { color: var(--text-muted); }

/* ========================================
   CTA SECTION
======================================== */
.cta-section { background: var(--navy-2); padding: 20px 0; }

.cta-box {
    position: relative;
    background: linear-gradient(135deg, rgba(20, 184, 166, 0.1), rgba(6, 182, 212, 0.05));
    border: 1px solid rgba(20, 184, 166, 0.25);
    border-radius: 24px;
    padding: 80px 40px;
    text-align: center;
    overflow: hidden;
}

.cta-glow {
    position: absolute;
    top: -50%;
    left: 50%;
    transform: translateX(-50%);
    width: 500px;
    height: 300px;
    background: rgba(20, 184, 166, 0.12);
    border-radius: 50%;
    filter: blur(60px);
}

.cta-content { position: relative; z-index: 1; }
.cta-content h2 { font-size: clamp(1.8rem, 3vw, 2.5rem); font-weight: 800; margin-bottom: 16px; letter-spacing: -1px; }
.cta-content p { color: var(--text-muted); margin-bottom: 36px; font-size: 1.05rem; }
.cta-buttons { display: flex; justify-content: center; gap: 16px; flex-wrap: wrap; }

/* ========================================
   FOOTER
======================================== */
.footer {
    background: var(--navy);
    border-top: 1px solid var(--glass-border);
    padding: 48px 24px 32px;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 24px;
    align-items: center;
    text-align: center;
}

.footer-brand .nav-brand { justify-content: center; }
.footer-brand p { color: var(--text-muted); font-size: 0.88rem; margin-top: 10px; }

.footer-links { display: flex; gap: 24px; flex-wrap: wrap; justify-content: center; }
.footer-links a { color: var(--text-dim); text-decoration: none; font-size: 0.88rem; transition: var(--transition); }
.footer-links a:hover { color: var(--teal); }
.footer-bottom { border-top: 1px solid var(--glass-border); width: 100%; padding-top: 20px; }
.footer-bottom p { color: var(--text-dim); font-size: 0.82rem; }

/* ========================================
   DETECT PAGE
======================================== */
.detect-page { background: var(--navy); min-height: 100vh; }

.detect-main {
    padding-top: 90px;
    min-height: 100vh;
}

.detect-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 24px 60px;
}

.detect-header {
    text-align: center;
    margin-bottom: 36px;
}

.detect-header h1 {
    font-size: clamp(1.8rem, 3vw, 2.5rem);
    font-weight: 800;
    letter-spacing: -1px;
    margin-bottom: 8px;
}

.detect-header p { color: var(--text-muted); font-size: 1rem; }

.detect-tabs {
    display: flex;
    gap: 8px;
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: 14px;
    padding: 6px;
    margin-bottom: 28px;
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
}

.tab-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 20px;
    border: none;
    border-radius: 10px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    background: transparent;
    color: var(--text-muted);
}

.tab-btn svg { width: 18px; height: 18px; }

.tab-btn.active {
    background: linear-gradient(135deg, var(--teal), var(--cyan));
    color: #fff;
    box-shadow: 0 4px 15px rgba(20, 184, 166, 0.3);
}

.tab-btn:not(.active):hover { color: var(--text); background: rgba(255,255,255,0.05); }

.detect-panel { display: none; }
.detect-panel.active { display: block; }

.detect-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    min-height: 520px;
}

/* Camera */
.camera-section { width: 100%; }

.camera-wrapper {
    background: var(--navy-3);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    height: 500px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.camera-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 40px;
    text-align: center;
    width: 100%;
    height: 100%;
}

.cam-icon-wrap {
    width: 80px;
    height: 80px;
    border-radius: 24px;
    background: rgba(20, 184, 166, 0.1);
    border: 1px solid rgba(20, 184, 166, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--teal);
}

.cam-icon-wrap svg { width: 36px; height: 36px; }
.cam-icon-wrap.red { background: rgba(239, 68, 68, 0.1); border-color: rgba(239, 68, 68, 0.25); color: #f87171; }
.camera-state h3 { font-size: 1.2rem; font-weight: 700; }
.camera-state p { color: var(--text-muted); font-size: 0.9rem; max-width: 260px; line-height: 1.6; }

.camera-active {
    position: relative;
    width: 100%;
    height: 100%;
}

.camera-active video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.camera-overlay {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.scan-box {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 70%;
    height: 60%;
    overflow: hidden;
}

.scan-box .corner { width: 28px; height: 28px; }
.scan-box .corner.tl { top: 0; left: 0; border-top: 3px solid var(--teal); border-left: 3px solid var(--teal); border-radius: 4px 0 0 0; }
.scan-box .corner.tr { top: 0; right: 0; border-top: 3px solid var(--teal); border-right: 3px solid var(--teal); border-radius: 0 4px 0 0; }
.scan-box .corner.bl { bottom: 0; left: 0; border-bottom: 3px solid var(--teal); border-left: 3px solid var(--teal); border-radius: 0 0 0 4px; }
.scan-box .corner.br { bottom: 0; right: 0; border-bottom: 3px solid var(--teal); border-right: 3px solid var(--teal); border-radius: 0 0 4px 0; }

.scan-line-anim {
    position: absolute;
    left: 0; right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--teal), transparent);
    top: 0;
    animation: camScan 2.5s ease-in-out infinite;
}

@keyframes camScan {
    0% { top: 0; }
    100% { top: 100%; }
}

.cam-status-badge {
    position: absolute;
    top: 16px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(0,0,0,0.5);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.1);
    color: var(--text-muted);
    font-size: 0.82rem;
    font-weight: 600;
    padding: 6px 14px;
    border-radius: 100px;
    white-space: nowrap;
}

.pulse-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--emerald);
    animation: pulse 1.5s ease-in-out infinite;
}

.camera-controls {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 16px;
    pointer-events: all;
}

.cam-ctrl-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(0,0,0,0.5);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.15);
    color: var(--text);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}

.cam-ctrl-btn svg { width: 22px; height: 22px; }
.cam-ctrl-btn:hover { background: rgba(255,255,255,0.1); }

.capture-btn {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, var(--teal), var(--cyan));
    border-color: transparent;
    box-shadow: 0 0 25px rgba(20, 184, 166, 0.5);
}

.capture-btn:hover {
    transform: scale(1.08);
    box-shadow: 0 0 35px rgba(20, 184, 166, 0.7);
}

/* Upload / Dropzone */
.upload-section { display: flex; flex-direction: column; gap: 16px; }

.dropzone {
    height: 440px;
    border: 2px dashed var(--glass-border);
    border-radius: var(--radius-lg);
    background: var(--navy-3);
    position: relative;
    overflow: hidden;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.dropzone:hover, .dropzone.drag-over {
    border-color: var(--teal);
    background: rgba(20, 184, 166, 0.05);
}

.dropzone-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 40px;
    text-align: center;
}

.dz-icon {
    width: 72px;
    height: 72px;
    border-radius: 20px;
    background: rgba(20, 184, 166, 0.1);
    border: 1px solid rgba(20, 184, 166, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--teal);
    margin-bottom: 8px;
}

.dz-icon svg { width: 32px; height: 32px; }
.dropzone-content h3 { font-size: 1.05rem; font-weight: 700; }
.dropzone-content p { color: var(--text-muted); font-size: 0.88rem; }
.dz-hint { font-size: 0.78rem !important; color: var(--text-dim) !important; }
input[type="file"].hidden { display: none; }

.dropzone-preview {
    width: 100%;
    height: 100%;
    position: absolute;
    inset: 0;
}

.dropzone-preview img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: var(--navy-4);
}

.dz-remove-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.15);
    color: var(--text);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}

.dz-remove-btn:hover { background: rgba(239,68,68,0.4); }
.dz-remove-btn svg { width: 16px; height: 16px; }

/* Result Section */
.result-section {
    background: var(--navy-3);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.result-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 40px;
    text-align: center;
    color: var(--text-dim);
}

.result-placeholder-icon {
    width: 64px;
    height: 64px;
    border-radius: 18px;
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--glass-border);
    display: flex;
    align-items: center;
    justify-content: center;
}

.result-placeholder-icon svg { width: 28px; height: 28px; }
.result-placeholder p { font-size: 0.88rem; line-height: 1.7; }

.result-card {
    width: 100%;
    height: 100%;
    padding: 28px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-self: start;
}

/* Result states */
.result-status-icon {
    width: 80px;
    height: 80px;
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    font-size: 2.5rem;
}

.result-status-icon.fresh { background: rgba(16,185,129,0.15); border: 1.5px solid rgba(16,185,129,0.35); }
.result-status-icon.not-fresh { background: rgba(239,68,68,0.12); border: 1.5px solid rgba(239,68,68,0.3); }
.result-status-icon.uncertain { background: rgba(234,179,8,0.12); border: 1.5px solid rgba(234,179,8,0.3); }
.result-status-icon.not-fish { background: rgba(100,116,139,0.15); border: 1.5px solid rgba(100,116,139,0.3); }

.result-label {
    text-align: center;
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -0.5px;
}

.result-label.fresh { color: var(--emerald); }
.result-label.not-fresh { color: #f87171; }
.result-label.uncertain { color: var(--yellow); }
.result-label.not-fish { color: var(--text-muted); }

.result-message {
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    padding: 14px 16px;
    font-size: 0.88rem;
    color: var(--text-muted);
    text-align: center;
    line-height: 1.6;
}

.result-detections { display: flex; flex-direction: column; gap: 10px; }
.result-detections h4 { font-size: 0.8rem; font-weight: 600; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.5px; }

.detection-item {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    padding: 12px 14px;
}

.detection-label {
    font-size: 0.88rem;
    font-weight: 600;
    flex: 1;
}

.detection-label.fresh { color: var(--emerald); }
.detection-label.not-fresh { color: #f87171; }

.detection-conf-bar { flex: 2; height: 6px; background: rgba(255,255,255,0.08); border-radius: 3px; overflow: hidden; }
.detection-conf-fill { height: 100%; border-radius: 3px; }
.detection-conf-fill.fresh { background: linear-gradient(90deg, var(--emerald-2), var(--emerald)); }
.detection-conf-fill.not-fresh { background: linear-gradient(90deg, #dc2626, #ef4444); }

.detection-pct { font-size: 0.82rem; font-weight: 700; color: var(--text-muted); min-width: 42px; text-align: right; }

.result-try-again {
    margin-top: auto;
    padding-top: 8px;
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--glass);
    border: 1px solid var(--glass-border);
    color: var(--text-muted);
    font-size: 0.88rem;
    font-weight: 600;
    padding: 11px 20px;
    border-radius: 10px;
    cursor: pointer;
    transition: var(--transition);
    width: 100%;
    justify-content: center;
    text-decoration: none;
}

.btn-secondary svg { width: 16px; height: 16px; }
.btn-secondary:hover { color: var(--text); border-color: rgba(255,255,255,0.2); background: rgba(255,255,255,0.06); }

/* ========================================
   LOADING OVERLAY
======================================== */
.loading-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(6,15,30,0.8);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
}

.loading-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    background: var(--navy-3);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 40px 48px;
    text-align: center;
}

.spinner {
    width: 48px;
    height: 48px;
    border: 3px solid rgba(20,184,166,0.2);
    border-top-color: var(--teal);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

.loading-box p { font-size: 1.05rem; font-weight: 600; color: var(--text); }
.loading-box span { font-size: 0.85rem; color: var(--text-muted); }

/* ========================================
   PARTICLES
======================================== */
.particles {
    position: absolute;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
}

.particle {
    position: absolute;
    border-radius: 50%;
    animation: particleFloat linear infinite;
    opacity: 0;
}

@keyframes particleFloat {
    0% { transform: translateY(100vh) scale(0); opacity: 0; }
    10% { opacity: 0.6; }
    90% { opacity: 0.2; }
    100% { transform: translateY(-20px) scale(1); opacity: 0; }
}

/* ========================================
   BOUNDING BOX PREVIEW
======================================== */
.result-bbox-preview {
    width: 100%;
    border-radius: var(--radius-sm);
    overflow: hidden;
    background: var(--navy-4);
    border: 1px solid var(--glass-border);
    position: relative;
    display: none;
    max-height: 280px;
}

.result-bbox-preview.hidden { display: none !important; }
.result-bbox-preview:not(.hidden) { display: block; }

.result-bbox-preview canvas {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    max-height: 280px;
}

/* ========================================
   RESPONSIVE – 900px breakpoint
======================================== */
@media (max-width: 900px) {
    /* Hero */
    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
        padding: 40px 24px 60px;
        gap: 40px;
    }
    .hero-visual { order: -1; }
    .hero-desc { max-width: 100%; margin-left: auto; margin-right: auto; }
    .hero-stats { justify-content: center; }
    .hero-actions { justify-content: center; }
    .hero-badge { margin-left: auto; margin-right: auto; }

    /* Features */
    .features-grid { grid-template-columns: repeat(2, 1fr); }

    /* Accuracy */
    .accuracy-grid { grid-template-columns: 1fr; gap: 40px; }
    .accuracy-content .section-title,
    .accuracy-content .section-tag { text-align: center; }
    .accuracy-content p { text-align: center; }

    /* Steps */
    .steps-container { flex-direction: column; align-items: stretch; }
    .step-arrow { transform: rotate(90deg); align-self: center; }
    .step-card { max-width: 100%; width: 100%; }

    /* Detect layout — stacked on tablet */
    .detect-layout {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    /* Result section fills naturally */
    .result-section {
        min-height: 200px;
        align-items: flex-start;
    }
}

/* ========================================
   RESPONSIVE – 620px (mobile)
======================================== */
@media (max-width: 620px) {
    /* Navbar */
    .nav-links { display: none; }
    .nav-hamburger { display: flex; }
    .btn-ghost-sm {
        padding: 8px 12px;
        font-size: 0.8rem;
        gap: 6px;
        white-space: nowrap;
    }
    .btn-ghost-sm span { display: none; }


    /* Hero */
    .hero-title { font-size: clamp(2rem, 10vw, 2.8rem); letter-spacing: -1.5px; }
    .hero-desc { font-size: 0.95rem; }
    .hero-stats { flex-direction: row; gap: 16px; justify-content: center; flex-wrap: wrap; }
    .stat-divider { width: 1px; height: 32px; }
    .stat-number { font-size: 1.5rem; }
    .phone-frame { width: 210px; }
    .phone-screen { max-height: 380px; }
    .hero-actions { flex-direction: column; width: 100%; }
    .hero-actions .btn-primary,
    .hero-actions .btn-ghost {
        justify-content: center;
        width: 100%;
    }

    /* Section padding */
    .section-container { padding: 60px 16px; }
    .section-header { margin-bottom: 40px; }

    /* Features */
    .features-grid { grid-template-columns: 1fr; gap: 14px; }
    .feature-card { padding: 22px; }

    /* Steps */
    .step-card { padding: 28px 20px; }

    /* CTA */
    .cta-box { padding: 50px 24px; }
    .cta-buttons { flex-direction: column; align-items: center; }
    .cta-buttons .btn-primary,
    .cta-buttons .btn-outline { width: 100%; max-width: 320px; justify-content: center; }

    /* Detect page */
    .detect-container { padding: 20px 14px 48px; }
    .detect-header h1 { font-size: 1.6rem; }
    .detect-header { margin-bottom: 20px; }
    .detect-tabs {
        max-width: 100%;
        padding: 5px;
    }
    .tab-btn {
        padding: 10px 12px;
        font-size: 0.82rem;
        gap: 6px;
    }
    .tab-btn svg { width: 16px; height: 16px; }

    /* Camera */
    .camera-wrapper { height: 380px; }
    .capture-btn { width: 64px; height: 64px; }
    .cam-ctrl-btn { width: 44px; height: 44px; }
    .camera-controls { gap: 12px; }
    .scan-box { width: 80%; height: 65%; }
    .cam-status-badge { font-size: 0.75rem; padding: 5px 12px; }

    /* Upload */
    .dropzone { height: 300px; }
    .dropzone-content { padding: 28px 20px; gap: 10px; }
    .dropzone-content h3 { font-size: 0.95rem; }
    .dz-icon { width: 56px; height: 56px; }
    .dz-icon svg { width: 24px; height: 24px; }

    /* Result */
    .result-section { min-height: 160px; border-radius: var(--radius); }
    .result-card { padding: 20px 16px; gap: 14px; }
    .result-status-icon { width: 64px; height: 64px; font-size: 2rem; border-radius: 18px; }
    .result-label { font-size: 1.25rem; }
    .result-message { font-size: 0.83rem; padding: 12px 14px; }
    .detection-item { padding: 10px 12px; }
    .detection-label { font-size: 0.82rem; }
    .detection-pct { font-size: 0.78rem; }
    .result-bbox-preview { max-height: 220px; }
    .result-bbox-preview canvas { max-height: 220px; }

    /* Loading */
    .loading-box { padding: 32px 28px; }
    .loading-box p { font-size: 0.95rem; }
}

/* ========================================
   RESPONSIVE – 400px (very small mobile)
======================================== */
@media (max-width: 400px) {
    .stat-item { align-items: center; }
    .hero-stats { gap: 12px; }
    .phone-frame { width: 180px; }
    .phone-screen { max-height: 320px; }
    .camera-wrapper { height: 300px; }
    .detect-header h1 { font-size: 1.4rem; }
    .tab-btn svg { display: none; }
    .tab-btn { font-size: 0.85rem; }
}

/* ========================================
   TOUCH / HOVER IMPROVEMENTS
======================================== */
@media (hover: none) {
    /* Disable hover transforms on touch devices to avoid sticky states */
    .feature-card:hover { transform: none; }
    .step-card:hover { transform: none; }
    .btn-primary:hover { transform: none; box-shadow: none; }
    .btn-outline:hover { transform: none; }
    .btn-nav-cta:hover { transform: none; box-shadow: none; }
}
