.hero-title {
    font-size: 2.75rem;
    line-height: 1.5;
    font-weight: 900;
}

@media (max-width: 640px) {
    .hero-title {
        font-size: 1.85rem;
    }
}

.cyber-glass {
    backdrop-filter: blur(16px) saturate(160%);
    -webkit-backdrop-filter: blur(16px) saturate(160%);
    background-color: rgba(13, 19, 33, 0.65);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

html:not(.dark) .cyber-glass {
    background-color: rgba(255, 255, 255, 0.88);
    border: 1px solid rgba(15, 23, 42, 0.1);
}

.scanline::after {
    content: '';
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(
        to bottom,
        transparent 0,
        transparent 2px,
        rgba(6, 182, 212, 0.03) 2px,
        rgba(6, 182, 212, 0.03) 4px
    );
    pointer-events: none;
}

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

/* مودال مشخصات دوره — ترمینال روشن */
.karsaz-course-modal__title {
    margin: 0 0 0.75rem;
    font-size: 1.25rem;
    line-height: 1.6;
    font-weight: 900;
    color: #0891b2;
    font-family: "Bon", sans-serif;
}

.karsaz-course-modal__subtitle {
    margin: 0 0 0.85rem;
    font-size: 0.75rem;
    font-weight: 600;
    color: #64748b;
    font-family: "Bon", sans-serif;
}

.karsaz-course-modal__list {
    margin: 0;
    padding: 0;
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.karsaz-course-modal__item {
    margin: 0;
    padding: 0.55rem 0.85rem 0.55rem 0.5rem;
    border-right: 2px solid rgba(6, 182, 212, 0.55);
    border-radius: 0 0.5rem 0.5rem 0;
    background: rgba(255, 255, 255, 0.72);
    color: #334155;
    font-size: 0.8125rem;
    line-height: 1.75;
    font-family: "Bon", sans-serif;
    font-weight: 500;
    transition: color 0.15s ease, background-color 0.15s ease, border-color 0.15s ease;
}

.karsaz-course-modal__item:hover {
    color: #0f172a;
    background: #fff;
    border-right-color: #06b6d4;
}

html.dark .karsaz-course-modal {
    background: #0f172a;
    border-color: rgba(148, 163, 184, 0.2);
}

html.dark .karsaz-course-modal > div:first-child,
html.dark .karsaz-course-modal > div:last-child {
    background: #111827;
    border-color: rgba(148, 163, 184, 0.15);
}

html.dark .karsaz-course-modal > div:nth-child(2) {
    background: #1e293b;
}

html.dark .karsaz-course-modal__title {
    color: #22d3ee;
}

html.dark .karsaz-course-modal__subtitle {
    color: #94a3b8;
}

html.dark .karsaz-course-modal__item {
    background: rgba(15, 23, 42, 0.55);
    color: #e2e8f0;
}

html.dark .karsaz-course-modal__item:hover {
    color: #fff;
    background: rgba(15, 23, 42, 0.9);
}

/* ===== Student results / story cards ===== */
.karsaz-story {
    display: flex;
    flex-direction: column;
    min-height: 0;
    border-radius: 8px;
}

.karsaz-story__media {
    flex: 1 1 auto;
    width: 100%;
    min-height: 0;
    height: 100%;
    aspect-ratio: 3 / 4;
}

@media (min-width: 640px) {
    .karsaz-story__media {
        aspect-ratio: 4 / 5;
    }
}

@media (min-width: 1280px) {
    .karsaz-story__media {
        aspect-ratio: auto;
    }
}

.karsaz-story__veil {
    background:
        linear-gradient(180deg, rgba(5, 7, 12, 0.15) 0%, transparent 28%, transparent 42%, rgba(5, 7, 12, 0.55) 68%, rgba(5, 7, 12, 0.96) 100%),
        radial-gradient(ellipse at 50% 0%, transparent 40%, rgba(5, 7, 12, 0.35) 100%);
}

.karsaz-story__scan {
    background: linear-gradient(
        115deg,
        transparent 0%,
        rgba(255, 255, 255, 0.03) 42%,
        rgba(255, 255, 255, 0.08) 50%,
        rgba(255, 255, 255, 0.03) 58%,
        transparent 100%
    );
    mix-blend-mode: soft-light;
}

.karsaz-story__chip {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.35rem 0.7rem;
    border-radius: 999px;
    font-size: 0.625rem;
    font-weight: 900;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.14);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
    color: #ecfdf5;
}

.karsaz-story__chip--emerald {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.55), rgba(6, 78, 59, 0.65));
}

.karsaz-story__chip--fuchsia {
    background: linear-gradient(135deg, rgba(217, 70, 239, 0.55), rgba(112, 26, 117, 0.65));
}

.karsaz-story__chip-dot {
    width: 0.375rem;
    height: 0.375rem;
    border-radius: 999px;
    background: currentColor;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.15);
    animation: karsazStoryPulse 1.8s ease-in-out infinite;
}

.karsaz-story__play {
    background: transparent;
    border: 0;
    cursor: pointer;
}

.karsaz-story__play-ring {
    width: 3.75rem;
    height: 3.75rem;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.28);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow:
        0 0 0 8px rgba(255, 255, 255, 0.04),
        0 16px 40px rgba(0, 0, 0, 0.45);
    transition: transform 0.35s ease, background 0.35s ease, box-shadow 0.35s ease, opacity 0.35s ease;
}

.karsaz-story__play-ring--emerald {
    background: rgba(16, 185, 129, 0.22);
}

.karsaz-story__play-ring--fuchsia {
    background: rgba(217, 70, 239, 0.22);
}

.karsaz-story:hover .karsaz-story__play-ring {
    transform: scale(1.08);
}

.karsaz-story.is-playing .karsaz-story__play-ring {
    opacity: 0;
    transform: scale(0.85);
    pointer-events: none;
}

.karsaz-story.is-playing .karsaz-story__play:hover .karsaz-story__play-ring,
.karsaz-story.is-playing .karsaz-story__play:focus-visible .karsaz-story__play-ring {
    opacity: 1;
    transform: scale(1);
    pointer-events: auto;
}

.karsaz-story.is-playing .karsaz-story__video {
    opacity: 1;
    filter: none;
}

.karsaz-story__video {
    opacity: 0.82;
    filter: saturate(1.05) contrast(1.05);
    transition: opacity 0.5s ease, filter 0.5s ease, transform 1.2s ease;
}

.karsaz-story:hover .karsaz-story__video {
    opacity: 0.95;
}

.karsaz-story__metric {
    padding: 0.55rem 0.65rem;
    border-radius: 0.85rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.karsaz-story__metric span {
    display: block;
    color: #94a3b8;
    font-size: 0.625rem;
    margin-bottom: 0.2rem;
}

.karsaz-story__metric strong {
    display: block;
    color: #fff;
    font-size: 0.7rem;
    font-weight: 800;
    line-height: 1.35;
}

.karsaz-observatory {
    border-radius: 8px;
}

.karsaz-observatory__stat {
    padding: 0.9rem 1rem;
    border-radius: 1.1rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: border-color 0.3s ease, background 0.3s ease;
}

.karsaz-observatory__stat:hover {
    background: rgba(255, 255, 255, 0.035);
    border-color: rgba(52, 211, 153, 0.22);
}

.karsaz-observatory__value {
    font-size: clamp(1.85rem, 2.4vw, 2.35rem);
    font-weight: 900;
    line-height: 1.15;
    letter-spacing: -0.02em;
}

.karsaz-observatory__bar {
    animation: karsazBarGrow 1.4s ease-out both;
    transform-origin: right center;
}

.karsaz-observatory__stack span {
    display: inline-flex;
    align-items: center;
    padding: 0.28rem 0.55rem;
    border-radius: 0.45rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(15, 23, 42, 0.45);
    color: #94a3b8;
    font-size: 0.625rem;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

@keyframes karsazStoryPulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.55; transform: scale(0.85); }
}

@keyframes karsazBarGrow {
    from { transform: scaleX(0); opacity: 0.4; }
    to { transform: scaleX(1); opacity: 1; }
}

html:not(.dark) #student-results.karsaz-results {
    background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 50%, #f8fafc 100%) !important;
}

html:not(.dark) .karsaz-story,
html:not(.dark) .karsaz-story .text-white,
html:not(.dark) .karsaz-story h3 {
    color: #fff !important;
}

html:not(.dark) .karsaz-story {
    background: #0b1220;
    border-color: rgba(15, 23, 42, 0.12);
}

html:not(.dark) .karsaz-story p,
html:not(.dark) .karsaz-story .text-slate-200\/90,
html:not(.dark) .karsaz-story .text-slate-300\/80,
html:not(.dark) .karsaz-story .text-slate-300\/90 {
    color: rgba(226, 232, 240, 0.92) !important;
}

html:not(.dark) .karsaz-story__metric span {
    color: #94a3b8 !important;
}

html:not(.dark) .karsaz-story__metric strong {
    color: #fff !important;
}

html:not(.dark) .karsaz-story__metric strong.text-emerald-300 {
    color: #6ee7b7 !important;
}

html:not(.dark) .karsaz-story__metric strong.text-fuchsia-300 {
    color: #f0abfc !important;
}

html:not(.dark) .karsaz-observatory.cyber-glass {
    background-color: rgba(255, 255, 255, 0.92) !important;
}

html:not(.dark) .karsaz-observatory h3 {
    color: #0f172a !important;
}

html:not(.dark) .karsaz-observatory__value {
    color: #0f172a !important;
}

html:not(.dark) .karsaz-observatory__value.text-emerald-400 {
    color: #059669 !important;
    -webkit-text-fill-color: #059669;
    background: none !important;
}

html:not(.dark) .karsaz-observatory__value.text-cyan-300 {
    color: #0891b2 !important;
    -webkit-text-fill-color: #0891b2;
    background: none !important;
}

html:not(.dark) .karsaz-observatory__value.text-transparent {
    background-image: linear-gradient(90deg, #0f172a, #64748b) !important;
    -webkit-text-fill-color: transparent;
    color: transparent !important;
}

html:not(.dark) .karsaz-observatory__stat {
    background: rgba(15, 23, 42, 0.03);
    border-color: rgba(15, 23, 42, 0.08);
}

html:not(.dark) .karsaz-observatory__stack span {
    background: rgba(15, 23, 42, 0.04);
    border-color: rgba(15, 23, 42, 0.1);
    color: #64748b;
}

