:root {
    --hk-foreground: #121212;
    --hk-background: #ffffff;
    --hk-oatmeal: #f7e3d1;
    --hk-terracotta: #C05131;
    --hk-off-white: #fcf8f2;
    --hk-nutmeg: #e4d3bb;
    --hk-rust: #e08c3b;
    --hk-powder-green: #bdc7c2;
    --hk-sage-green: #739a82;
    --hk-cool-blue: #abb5c7;
    --hk-navy: #384045;
    --hk-sandstone: #f7f2eb;
    --hk-beige: #f2e8e3;
    --hk-text-muted: #4d4d4d;
    --hk-text-subtle: #8a8a8a;
    --hk-line: #ececec;
    --hk-dark: #242833;
    --hk-page-width: 1200px;

    --hk-swatch-dark-anthracite: #3D3D3D;
    --hk-swatch-dark-olive: #5C6B52;
    --hk-swatch-choco: #6B4E3D;
    --hk-swatch-sandy-taupe: #C4B5A4;
}

*, *::before, *::after { box-sizing: border-box; }

body {
    font-family: 'GT-Eesti-Display', system-ui, -apple-system, sans-serif;
    background: var(--hk-background);
    color: var(--hk-foreground);
    margin: 0;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    font-size: 16px;
    line-height: 1.6;
}

a { color: inherit; text-decoration: none; }

.hk-container {
    max-width: var(--hk-page-width);
    margin-left: auto;
    margin-right: auto;
    padding-left: 1rem;
    padding-right: 1rem;
}
@media (min-width: 768px) {
    .hk-container { padding-left: 2rem; padding-right: 2rem; }
}

.hk-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 32px;
    font-family: inherit;
    font-size: 13px;
    font-weight: 400;
    letter-spacing: 0.03em;
    border: 1px solid transparent;
    cursor: pointer;
    border-radius: 0;
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.hk-btn-primary {
    background: var(--hk-foreground);
    color: var(--hk-background);
    border-color: var(--hk-foreground);
}
.hk-btn-primary:hover {
    background: #333;
    border-color: #333;
}

.color-swatch {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 2px solid transparent;
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.2s ease;
    padding: 0;
    outline: none;
}
.color-swatch:hover { transform: scale(1.15); }
.color-swatch:focus-visible { outline: 2px solid var(--hk-terracotta); outline-offset: 2px; }
.color-swatch.active { box-shadow: 0 0 0 2px var(--hk-background), 0 0 0 4px var(--hk-foreground); }

#product-gallery { position: relative; }
.product-img { transition: opacity 0.5s ease; width: 100%; display: block; }
.product-img.is-hidden { opacity: 0; position: absolute; inset: 0; pointer-events: none; }
.product-img.is-active { opacity: 1; position: relative; }

.lang-switch a {
    font-size: 12px;
    font-weight: 500;
    color: var(--hk-text-subtle);
    padding: 4px 0;
    transition: color 0.15s ease;
    letter-spacing: 0.05em;
}
.lang-switch a:hover { color: var(--hk-foreground); }
.lang-switch a.active { color: var(--hk-foreground); }

.hero-section { position: relative; overflow: hidden; }
.hero-section::before {
    content: '';
    position: absolute;
    top: -15%; right: -8%; width: 65%; height: 130%;
    background: radial-gradient(ellipse at 55% 45%, rgba(247,227,209,0.28) 0%, rgba(252,248,242,0.18) 35%, rgba(192,81,49,0.04) 55%, transparent 72%);
    pointer-events: none;
    z-index: 0;
}
.hero-section::after {
    content: '';
    position: absolute;
    bottom: -20%; left: -12%; width: 45%; height: 80%;
    background: radial-gradient(ellipse at 50% 55%, rgba(247,227,209,0.14) 0%, rgba(252,248,242,0.06) 45%, transparent 68%);
    pointer-events: none;
    z-index: 0;
}

.info-card {
    background: var(--hk-off-white);
    border: 1px solid var(--hk-line);
    border-radius: 16px;
    padding: 20px 24px;
    transition: border-color 0.2s ease;
}
.info-card:hover { border-color: var(--hk-nutmeg); }

.timeline { display: grid; grid-template-columns: 1fr; gap: 0; position: relative; }
@media (min-width: 768px) { .timeline { grid-template-columns: 1fr 1fr 1fr; } }

.timeline-step { display: flex; flex-direction: column; align-items: center; text-align: center; position: relative; padding: 0 16px; }
.timeline-dot { width: 12px; height: 12px; border-radius: 50%; background: var(--hk-terracotta); flex-shrink: 0; position: relative; z-index: 1; }
.timeline-line { display: none; }
@media (min-width: 768px) {
    .timeline-line { display: block; position: absolute; top: 6px; left: 0; right: 0; height: 1px; background: var(--hk-terracotta); opacity: 0.25; z-index: 0; }
}
.timeline-step h3 { font-size: 14px; font-weight: 500; margin: 12px 0 4px; }
.timeline-step p { font-size: 13px; color: var(--hk-text-muted); line-height: 1.6; max-width: 240px; }

.accent-line { width: 32px; height: 2px; background: var(--hk-terracotta); display: block; flex-shrink: 0; }

.reveal { opacity: 0; transform: translateY(20px); animation: revealUp 0.7s cubic-bezier(0.22, 1, 0.36, 1) forwards; }
.reveal-d1 { animation-delay: 0.05s; }
.reveal-d2 { animation-delay: 0.12s; }
.reveal-d3 { animation-delay: 0.2s; }
.reveal-d4 { animation-delay: 0.3s; }
.reveal-d5 { animation-delay: 0.42s; }
.reveal-d6 { animation-delay: 0.55s; }
.reveal-d7 { animation-delay: 0.7s; }

@keyframes revealUp { to { opacity: 1; transform: translateY(0); } }

@media (prefers-reduced-motion: reduce) {
    .reveal, .reveal-d1, .reveal-d2, .reveal-d3, .reveal-d4, .reveal-d5, .reveal-d6, .reveal-d7 { opacity: 1; transform: none; animation: none; }
    .product-img { transition: none; }
    .color-swatch { transition: none; }
}

/* Button variants */
.hk-btn-primary:disabled { opacity: 0.65; cursor: not-allowed; }
.hk-btn-secondary { background: transparent; color: var(--hk-foreground); border-color: var(--hk-foreground); }
.hk-btn-secondary:hover { background: var(--hk-foreground); color: var(--hk-background); }

/* Form styles */
.hk-form-group { margin-bottom: 20px; }
.hk-label { display: block; font-size: 13px; font-weight: 500; color: var(--hk-foreground); margin-bottom: 6px; letter-spacing: 0.01em; }
.hk-label-required::after { content: ' *'; color: var(--hk-terracotta); }
.hk-input { width: 100%; padding: 12px 14px; font-family: inherit; font-size: 14px; color: var(--hk-foreground); background: var(--hk-background); border: 1px solid var(--hk-line); border-radius: 0; transition: border-color 0.2s ease, box-shadow 0.2s ease; }
.hk-input:focus { outline: none; border-color: var(--hk-foreground); box-shadow: 0 0 0 1px var(--hk-foreground); }
.hk-input::placeholder { color: var(--hk-text-subtle); }
.hk-input.is-error { border-color: var(--hk-terracotta); }
.hk-input.is-error:focus { box-shadow: 0 0 0 1px var(--hk-terracotta); }
.hk-error { display: none; font-size: 12px; color: var(--hk-terracotta); margin-top: 4px; }
.hk-error.is-visible { display: block; }
.form-row { display: grid; grid-template-columns: 1fr; gap: 16px; }
@media (min-width: 640px) { .form-row-2 { grid-template-columns: 1fr 1fr; } .form-row-3 { grid-template-columns: 1fr 2fr; } }

/* Dropzone */
.hk-dropzone { border: 2px dashed var(--hk-line); border-radius: 6px; padding: 32px 24px; text-align: center; cursor: pointer; transition: border-color 0.2s ease, background-color 0.2s ease; background: var(--hk-off-white); }
.hk-dropzone:hover { border-color: var(--hk-nutmeg); }
.hk-dropzone.is-dragover { border-color: var(--hk-terracotta); background: var(--hk-oatmeal); }
.hk-dropzone.is-error { border-color: var(--hk-terracotta); }
.hk-dropzone-icon { width: 48px; height: 48px; margin: 0 auto 12px; color: var(--hk-text-subtle); }
.hk-dropzone-text { font-size: 14px; color: var(--hk-text-muted); margin-bottom: 4px; }
.hk-dropzone-hint { font-size: 12px; color: var(--hk-text-subtle); }

/* File preview */
.hk-file-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 12px; margin-top: 16px; }
.hk-file-item { position: relative; background: var(--hk-off-white); border: 1px solid var(--hk-line); border-radius: 6px; overflow: hidden; }
.hk-file-preview { aspect-ratio: 4/3; display: flex; align-items: center; justify-content: center; background: var(--hk-sandstone); overflow: hidden; }
.hk-file-preview img { width: 100%; height: 100%; object-fit: cover; }
.hk-file-preview-video { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; color: var(--hk-text-muted); }
.hk-file-preview-video svg { width: 32px; height: 32px; }
.hk-file-info { padding: 8px 10px; }
.hk-file-name { font-size: 11px; color: var(--hk-foreground); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-bottom: 2px; }
.hk-file-size { font-size: 10px; color: var(--hk-text-subtle); }
.hk-file-remove { position: absolute; top: 6px; right: 6px; width: 24px; height: 24px; display: flex; align-items: center; justify-content: center; background: rgba(0,0,0,0.6); border: none; border-radius: 50%; color: #fff; cursor: pointer; transition: background-color 0.15s ease; padding: 0; }
.hk-file-remove:hover { background: rgba(0,0,0,0.8); }
.hk-file-remove svg { width: 14px; height: 14px; }
.hk-file-count { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--hk-text-muted); margin-top: 12px; }
.hk-file-count-number { display: inline-flex; align-items: center; justify-content: center; min-width: 20px; height: 20px; padding: 0 6px; background: var(--hk-terracotta); color: #fff; font-size: 11px; font-weight: 500; border-radius: 10px; }

/* Privacy notice */
.hk-privacy-notice { font-size: 12px; color: var(--hk-text-muted); margin-top: 16px; line-height: 1.6; }
.hk-privacy-notice a { color: var(--hk-foreground); text-decoration: underline; }

/* Score colors */
:root { --hk-score-excellent: #22c55e; --hk-score-good: #84cc16; --hk-score-average: #eab308; --hk-score-low: #ef4444; }

/* Score display */
.score-container { background: linear-gradient(135deg, var(--hk-off-white) 0%, var(--hk-oatmeal) 100%); border-radius: 16px; padding: 40px; text-align: center; border: 1px solid var(--hk-nutmeg); }
.score-number { font-size: 80px; font-weight: 700; color: var(--hk-terracotta); line-height: 1; letter-spacing: -0.03em; }
@media (min-width: 768px) { .score-number { font-size: 120px; } }
.score-label { font-size: 14px; font-weight: 500; color: var(--hk-text-muted); text-transform: uppercase; letter-spacing: 0.1em; margin-top: 8px; }
.score-rating { display: inline-flex; align-items: center; gap: 8px; padding: 8px 16px; border-radius: 6px; font-size: 14px; font-weight: 500; margin-top: 16px; }
.score-rating.excellent { background: rgba(34, 197, 94, 0.15); color: #16a34a; }
.score-rating.good { background: rgba(132, 204, 22, 0.15); color: #65a30d; }
.score-rating.average { background: rgba(234, 179, 8, 0.15); color: #ca8a04; }
.score-rating.low { background: rgba(239, 68, 68, 0.15); color: #dc2626; }

/* File card */
.file-card { background: var(--hk-background); border: 1px solid var(--hk-line); border-radius: 12px; padding: 16px; display: flex; align-items: center; gap: 16px; transition: border-color 0.2s ease, box-shadow 0.2s ease; }
.file-card:hover { border-color: var(--hk-nutmeg); box-shadow: 0 4px 12px rgba(0,0,0,0.04); }
.file-card.analyzing { border-color: var(--hk-terracotta); }
.file-card.complete { border-color: var(--hk-score-excellent); }
.file-thumbnail { width: 64px; height: 64px; border-radius: 8px; object-fit: cover; background: var(--hk-sandstone); flex-shrink: 0; }
.file-icon { width: 64px; height: 64px; border-radius: 8px; background: var(--hk-sandstone); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.file-score { font-size: 18px; font-weight: 700; padding: 6px 12px; border-radius: 6px; margin-left: auto; flex-shrink: 0; }
.file-score.excellent { background: rgba(34, 197, 94, 0.15); color: #16a34a; }
.file-score.good { background: rgba(132, 204, 22, 0.15); color: #65a30d; }
.file-score.average { background: rgba(234, 179, 8, 0.15); color: #ca8a04; }
.file-score.low { background: rgba(239, 68, 68, 0.15); color: #dc2626; }

/* Feedback card */
.feedback-card { background: var(--hk-background); border: 1px solid var(--hk-line); border-radius: 16px; padding: 24px; }
.feedback-card.positive { border-left: 4px solid var(--hk-score-excellent); }
.feedback-card.tips { border-left: 4px solid var(--hk-score-average); }
.feedback-icon { width: 32px; height: 32px; border-radius: 50%; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.feedback-icon.positive { background: rgba(34, 197, 94, 0.15); color: #16a34a; }
.feedback-icon.tips { background: rgba(234, 179, 8, 0.15); color: #ca8a04; }

/* Next steps */
.step-item { display: flex; align-items: flex-start; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--hk-line); }
.step-item:last-child { border-bottom: none; }
.step-number { width: 28px; height: 28px; border-radius: 50%; background: var(--hk-terracotta); color: white; font-size: 13px; font-weight: 500; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }

/* Share link box */
.share-box { background: var(--hk-off-white); border: 1px solid var(--hk-line); border-radius: 12px; padding: 20px; }
.share-url { display: flex; align-items: center; gap: 12px; background: var(--hk-background); border: 1px solid var(--hk-line); border-radius: 6px; padding: 12px 16px; margin-top: 12px; }
.share-url input { flex: 1; border: none; background: transparent; font-family: inherit; font-size: 13px; color: var(--hk-text-muted); outline: none; }
.share-url button { background: var(--hk-foreground); color: var(--hk-background); border: none; padding: 8px 16px; font-family: inherit; font-size: 12px; font-weight: 500; cursor: pointer; transition: background-color 0.2s ease; }
.share-url button:hover { background: #333; }
.share-url button.copied { background: var(--hk-score-excellent); }

/* Success animation */
.success-check { width: 80px; height: 80px; border-radius: 50%; background: var(--hk-score-excellent); display: flex; align-items: center; justify-content: center; margin: 0 auto 24px; animation: scaleIn 0.4s cubic-bezier(0.22, 1, 0.36, 1); }
@keyframes scaleIn { from { transform: scale(0); opacity: 0; } to { transform: scale(1); opacity: 1; } }

/* Spinner */
.spinner { width: 32px; height: 32px; border: 3px solid rgba(255,255,255,0.3); border-top-color: #fff; border-radius: 50%; animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Progress status */
.progress-status { display: flex; align-items: center; gap: 12px; padding: 16px 20px; background: var(--hk-sandstone); border-radius: 8px; margin-bottom: 24px; }
.progress-spinner { width: 20px; height: 20px; border: 2px solid var(--hk-line); border-top-color: var(--hk-terracotta); border-radius: 50%; animation: spin 0.8s linear infinite; }
.progress-text { font-size: 14px; color: var(--hk-text-muted); }
.progress-status.complete { background: #dcfce7; }
.progress-status.complete .progress-text { color: #166534; }

/* Criteria scores */
.criteria-list { display: grid; gap: 12px; margin-top: 24px; }
.criteria-item { display: flex; align-items: center; gap: 16px; padding: 12px 16px; background: var(--hk-sandstone); border-radius: 8px; }
.criteria-label { flex: 1; font-size: 13px; color: var(--hk-text-muted); }
.criteria-score { font-size: 14px; font-weight: 500; color: var(--hk-foreground); }
.criteria-bar { flex: 2; height: 6px; background: var(--hk-line); border-radius: 3px; overflow: hidden; }
.criteria-bar-fill { height: 100%; background: var(--hk-terracotta); border-radius: 3px; transition: width 0.5s ease; }

/* Feedback section */
.feedback-section { margin-top: 32px; }
.feedback-title { font-size: 15px; font-weight: 500; margin-bottom: 12px; }
.feedback-list { display: flex; flex-direction: column; gap: 8px; }
.feedback-item { display: flex; align-items: flex-start; gap: 10px; font-size: 13px; color: var(--hk-text-muted); line-height: 1.5; }
.feedback-item .feedback-icon { width: 18px; height: 18px; margin-top: 1px; flex-shrink: 0; }
.feedback-item .feedback-icon.positive { color: #22c55e; background: none; }
.feedback-item .feedback-icon.tip { color: var(--hk-terracotta); background: none; }

/* Analyze file card */
.file-card-preview { aspect-ratio: 4/3; background: var(--hk-sandstone); display: flex; align-items: center; justify-content: center; overflow: hidden; position: relative; }
.file-card-preview img { width: 100%; height: 100%; object-fit: cover; }
.file-card-status { position: absolute; inset: 0; background: rgba(0,0,0,0.5); display: flex; align-items: center; justify-content: center; opacity: 0; transition: opacity 0.2s ease; }
.file-card.analyzing .file-card-status { opacity: 1; }
.file-card-body { padding: 12px 14px; }
.file-card-name { font-size: 12px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-bottom: 4px; }
.file-card-score { font-size: 11px; color: var(--hk-text-subtle); }
.file-card-score.has-score { color: var(--hk-foreground); font-weight: 500; }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    .success-check, .spinner, .progress-spinner { animation: none; }
}

/* ===== Analyze Page - Premium Redesign ===== */

/* Header */
.analyze-header { background: var(--hk-oatmeal); }
.header-logo { position: absolute; left: 50%; transform: translateX(-50%); }
.header-line { height: 1px; background: var(--hk-nutmeg); }

/* Main layout */
.analyze-main {
    background: linear-gradient(180deg, var(--hk-oatmeal) 0%, var(--hk-background) 50%);
    padding-bottom: 60px;
}

.analyze-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 32px 16px;
}
@media (min-width: 768px) {
    .analyze-container { padding: 48px 24px; }
}

/* Hero Section */
.analyze-hero {
    margin-bottom: 40px;
}

/* Gallery */
.analyze-gallery {
    position: relative;
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.08), 0 2px 8px rgba(0, 0, 0, 0.04);
    overflow: hidden;
}

.analyze-gallery-main {
    position: relative;
    aspect-ratio: 16/10;
    background: linear-gradient(135deg, var(--hk-sandstone) 0%, var(--hk-beige) 100%);
}

.analyze-gallery-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.analyze-gallery-video {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    color: var(--hk-text-muted);
}
.analyze-gallery-video span {
    font-size: 14px;
    max-width: 200px;
    text-align: center;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Glow effect during analysis */
.analyze-gallery-glow {
    position: absolute;
    inset: 0;
    border-radius: 20px;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.5s ease;
}
.analyze-gallery-glow.is-active {
    opacity: 1;
    box-shadow: inset 0 0 0 3px rgba(192, 81, 49, 0.3);
    animation: gallery-pulse 2s ease-in-out infinite;
}
.analyze-gallery-glow.is-complete {
    opacity: 1;
    box-shadow: inset 0 0 0 3px rgba(34, 197, 94, 0.4);
    animation: none;
}

@keyframes gallery-pulse {
    0%, 100% { box-shadow: inset 0 0 0 3px rgba(192, 81, 49, 0.2), 0 0 20px rgba(192, 81, 49, 0.1); }
    50% { box-shadow: inset 0 0 0 4px rgba(192, 81, 49, 0.4), 0 0 30px rgba(192, 81, 49, 0.2); }
}

/* Floating score badge on gallery */
.analyze-gallery-score {
    position: absolute;
    bottom: 20px;
    right: 20px;
    display: flex;
    align-items: baseline;
    gap: 2px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 12px 20px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    opacity: 0;
    transform: translateY(10px) scale(0.95);
    transition: opacity 0.4s ease, transform 0.4s ease;
}
.analyze-gallery-score.is-visible {
    opacity: 1;
    transform: translateY(0) scale(1);
}
.analyze-gallery-score-value {
    font-size: 32px;
    font-weight: 700;
    color: var(--hk-terracotta);
    line-height: 1;
}
.analyze-gallery-score-label {
    font-size: 16px;
    font-weight: 500;
    color: var(--hk-text-subtle);
}

/* Thumbnail strip */
.analyze-thumbs-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 16px;
    gap: 16px;
}

.analyze-thumbs {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding: 4px;
    margin: -4px;
    flex: 1;
}

.analyze-thumb-wrapper {
    position: relative;
    flex-shrink: 0;
}

.analyze-thumb {
    position: relative;
    width: 80px;
    height: 60px;
    border: 2px solid var(--hk-line);
    border-radius: 10px;
    overflow: hidden;
    cursor: pointer;
    background: var(--hk-sandstone);
    padding: 0;
    transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}
.analyze-thumb:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}
.analyze-thumb.active {
    border-color: var(--hk-terracotta);
    box-shadow: 0 0 0 3px rgba(192, 81, 49, 0.15);
}
.analyze-thumb.is-analyzing {
    border-color: var(--hk-terracotta);
    animation: thumb-pulse 1.5s ease-in-out infinite;
}
.analyze-thumb.is-complete {
    border-color: #22c55e;
}
.analyze-thumb.is-rejected {
    border-color: #f59e0b;
    opacity: 0.7;
}
.analyze-thumb.is-rejected::after {
    content: '!';
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(245, 158, 11, 0.85);
    color: #fff;
    font-weight: 700;
    font-size: 18px;
}
.analyze-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

@keyframes thumb-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(192, 81, 49, 0.4); }
    50% { box-shadow: 0 0 0 6px rgba(192, 81, 49, 0); }
}

.analyze-thumb-video {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--hk-text-muted);
    background: var(--hk-sandstone);
}

/* Checkmark status on thumbnail */
.analyze-thumb-status {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(34, 197, 94, 0.9);
    opacity: 0;
    transition: opacity 0.3s ease;
}
.analyze-thumb-status.is-visible { opacity: 1; }
.analyze-thumb-check { color: #fff; }

/* Remove button */
.analyze-thumb-remove {
    position: absolute;
    top: -10px;
    right: -10px;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--hk-foreground);
    color: #fff;
    border: 2px solid #fff;
    border-radius: 50%;
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.2s ease, transform 0.2s ease, background 0.2s ease;
    padding: 0;
    z-index: 2;
}
/* Touch-friendly: larger tap area via ::before pseudo-element */
.analyze-thumb-remove::before {
    content: '';
    position: absolute;
    inset: -8px;
}
.analyze-thumb-wrapper:hover .analyze-thumb-remove { opacity: 1; }
.analyze-thumb-remove:hover {
    transform: scale(1.1);
    background: var(--hk-terracotta);
}
.analyze-thumb-remove.is-confirming {
    opacity: 1;
    background: #dc2626;
    animation: confirm-pulse 0.5s ease infinite;
}
@keyframes confirm-pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.15); }
}
.analyze-thumb-remove:disabled { display: none; }
/* Always show on touch devices */
@media (hover: none) {
    .analyze-thumb-remove { opacity: 0.8; }
}

/* Add button */
.analyze-thumb-add {
    width: 80px;
    height: 60px;
    flex-shrink: 0;
    border: 2px dashed var(--hk-nutmeg);
    border-radius: 10px;
    background: transparent;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--hk-text-subtle);
    transition: all 0.2s ease;
    padding: 0;
}
.analyze-thumb-add:hover:not(:disabled) {
    border-color: var(--hk-terracotta);
    color: var(--hk-terracotta);
    background: rgba(192, 81, 49, 0.05);
}
.analyze-thumb-add:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.analyze-thumb-spinner {
    width: 20px;
    height: 20px;
    border: 2px solid var(--hk-line);
    border-top-color: var(--hk-terracotta);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.analyze-file-count {
    font-size: 13px;
    color: var(--hk-text-subtle);
    white-space: nowrap;
}

/* Content Section */
.analyze-content {
    max-width: 600px;
    margin: 0 auto;
}

/* Header block */
.analyze-header-block {
    text-align: center;
    margin-bottom: 32px;
}

.analyze-overline {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 16px;
}
.analyze-overline-line {
    width: 24px;
    height: 2px;
    background: var(--hk-terracotta);
}
.analyze-overline span {
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--hk-terracotta);
}

.analyze-title {
    font-size: 28px;
    font-weight: 500;
    letter-spacing: -0.02em;
    line-height: 1.2;
    margin: 0 0 12px;
}
@media (min-width: 768px) {
    .analyze-title { font-size: 36px; }
}

.analyze-subtitle {
    font-size: 15px;
    color: var(--hk-text-muted);
    line-height: 1.6;
    margin: 0;
}

/* Progress bar */
.analyze-progress {
    background: var(--hk-off-white);
    border: 1px solid var(--hk-line);
    border-radius: 12px;
    padding: 16px 20px;
    margin-bottom: 24px;
}
.analyze-progress.complete {
    background: #f0fdf4;
    border-color: #bbf7d0;
}
.analyze-progress.complete .analyze-progress-text { color: #166534; }
.analyze-progress.complete .analyze-progress-fill { background: #22c55e; }
.analyze-progress.error {
    background: #fef2f2;
    border-color: #fecaca;
}
.analyze-progress.error .analyze-progress-text { color: #991b1b; }
.analyze-progress.warning {
    background: #fffbeb;
    border-color: #fde68a;
}
.analyze-progress.warning .analyze-progress-text { color: #92400e; }

.analyze-progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}
.analyze-progress-text {
    font-size: 14px;
    color: var(--hk-text-muted);
}
.analyze-progress-count {
    font-size: 13px;
    font-weight: 500;
    color: var(--hk-foreground);
}

.analyze-progress-bar {
    height: 6px;
    background: var(--hk-line);
    border-radius: 3px;
    overflow: hidden;
}
.analyze-progress-fill {
    height: 100%;
    width: 0%;
    background: var(--hk-terracotta);
    border-radius: 3px;
    transition: width 0.4s ease;
}

/* Score card */
.analyze-score-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: linear-gradient(135deg, var(--hk-off-white) 0%, var(--hk-oatmeal) 100%);
    border: 1px solid var(--hk-nutmeg);
    border-radius: 16px;
    padding: 24px 28px;
    margin-bottom: 24px;
    animation: score-reveal 0.5s ease;
}
@keyframes score-reveal {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.analyze-score-main {
    display: flex;
    align-items: baseline;
    gap: 4px;
}
.analyze-score-value {
    font-size: 48px;
    font-weight: 700;
    color: var(--hk-terracotta);
    line-height: 1;
    letter-spacing: -0.03em;
}
.analyze-score-meta {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.analyze-score-max {
    font-size: 20px;
    font-weight: 500;
    color: var(--hk-text-subtle);
}
.analyze-score-label {
    font-size: 11px;
    font-weight: 500;
    color: var(--hk-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.analyze-score-badge {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--hk-oatmeal);
    border-radius: 50%;
    color: var(--hk-text-subtle);
}
.analyze-score-badge.excellent {
    background: #fef3c7;
    color: #d97706;
}
.analyze-score-badge.good {
    background: #dcfce7;
    color: #16a34a;
}
.analyze-score-badge.rejected {
    background: #fef2f2;
    color: #dc2626;
    font-size: 24px;
    font-weight: 700;
}

/* Criteria */
.analyze-criteria {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 24px;
    animation: criteria-reveal 0.5s ease 0.2s both;
}
@keyframes criteria-reveal {
    from { opacity: 0; }
    to { opacity: 1; }
}

.analyze-criteria-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: var(--hk-off-white);
    border-radius: 10px;
}
.analyze-criteria-label {
    flex: 0 0 110px;
    font-size: 13px;
    color: var(--hk-text-muted);
}
.analyze-criteria-bar {
    flex: 1;
    height: 8px;
    background: var(--hk-line);
    border-radius: 4px;
    overflow: hidden;
}
.analyze-criteria-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, var(--hk-terracotta) 0%, var(--hk-rust) 100%);
    border-radius: 4px;
    transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}
.analyze-criteria-value {
    flex: 0 0 40px;
    font-size: 13px;
    font-weight: 600;
    color: var(--hk-foreground);
    text-align: right;
}

/* Feedback cards */
.analyze-feedback {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 24px;
    animation: feedback-reveal 0.5s ease 0.4s both;
}
@keyframes feedback-reveal {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.analyze-feedback-card {
    display: flex;
    gap: 14px;
    padding: 16px 18px;
    border-radius: 12px;
}
.analyze-feedback-good {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
}
.analyze-feedback-good .analyze-feedback-icon { color: #22c55e; }
.analyze-feedback-tips {
    background: #fffbeb;
    border: 1px solid #fde68a;
}
.analyze-feedback-tips .analyze-feedback-icon { color: #d97706; }

.analyze-feedback-icon {
    flex-shrink: 0;
    margin-top: 2px;
}
.analyze-feedback-content { flex: 1; }
.analyze-feedback-content h3 {
    font-size: 14px;
    font-weight: 600;
    margin: 0 0 8px;
    color: var(--hk-foreground);
}
.analyze-feedback-content ul {
    margin: 0;
    padding: 0;
    list-style: none;
}
.analyze-feedback-content li {
    font-size: 13px;
    color: var(--hk-text-muted);
    line-height: 1.5;
    padding-left: 16px;
    position: relative;
    margin-bottom: 4px;
}
.analyze-feedback-content li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 8px;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: currentColor;
    opacity: 0.5;
}

/* Action buttons */
.analyze-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 32px;
}

.analyze-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 16px 24px;
    font-family: inherit;
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.02em;
    border: none;
    border-radius: 0;
    cursor: pointer;
    transition: all 0.2s ease;
}
.analyze-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.analyze-btn-primary {
    background: var(--hk-foreground);
    color: #fff;
}
.analyze-btn-primary:hover:not(:disabled) {
    background: #333;
}

.analyze-btn-secondary {
    background: var(--hk-off-white);
    color: var(--hk-foreground);
    border: 1px solid var(--hk-line);
}
.analyze-btn-secondary:hover:not(:disabled) {
    background: var(--hk-sandstone);
    border-color: var(--hk-nutmeg);
}

.analyze-link-back {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px;
    font-size: 13px;
    color: var(--hk-text-muted);
    transition: color 0.2s ease;
}
.analyze-link-back:hover {
    color: var(--hk-foreground);
}

/* Footer */
.analyze-footer { background: var(--hk-dark); }
.footer-accent { height: 3px; background: var(--hk-terracotta); }
.footer-content { color: rgba(255, 255, 255, 0.45); }
.footer-content a { transition: color 0.15s ease; }
.footer-content a:hover { color: rgba(255, 255, 255, 0.7); }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    .analyze-gallery-glow,
    .analyze-thumb,
    .analyze-gallery-score,
    .analyze-score-card,
    .analyze-criteria,
    .analyze-feedback {
        animation: none !important;
        transition: none !important;
    }
}
