/* ==========================================================================
   صفحه‌ی انتخاب پرتال — «شفق» (Aurora Glass)
   استایل اختصاصی همین صفحه؛ به app.css دست نمی‌زند.
   ========================================================================== */

.landing {
    --ink: #04070f;
    --navy: #0b1e3f;
    --blue: #2b61b2;
    --teal: #17b2a8;
    --violet: #6d5efc;

    --glass: rgba(255, 255, 255, .07);
    --glass-strong: rgba(255, 255, 255, .12);
    --line: rgba(255, 255, 255, .14);
    --line-soft: rgba(255, 255, 255, .08);
    --fg: #f2f6ff;
    --fg-soft: rgba(230, 239, 255, .78);
    --fg-muted: rgba(205, 219, 245, .64);

    position: relative;
    min-height: 100dvh;
    margin: 0;
    padding: clamp(18px, 4vw, 48px) clamp(14px, 3vw, 32px);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow-x: hidden;
    color: var(--fg);
    font-family: var(--font);
    background-color: var(--ink);
    background-image:
        radial-gradient(1200px 820px at 82% -12%, rgba(43, 97, 178, .55), transparent 62%),
        radial-gradient(1000px 720px at 8% 4%, rgba(23, 178, 168, .42), transparent 62%),
        radial-gradient(1100px 900px at 50% 118%, rgba(109, 94, 252, .34), transparent 62%),
        linear-gradient(180deg, #060c18 0%, #04070f 100%);
    background-attachment: fixed;
}

/* ــــ هاله‌های متحرک ــــ */
.landing__aurora {
    position: fixed;
    inset: -20%;
    z-index: 0;
    pointer-events: none;
    filter: blur(70px);
    opacity: .55;
}

.landing__aurora span {
    position: absolute;
    display: block;
    width: 46vmax;
    height: 46vmax;
    border-radius: 50%;
    mix-blend-mode: screen;
    animation: aurora-drift 26s cubic-bezier(.45, 0, .55, 1) infinite alternate;
}

.landing__aurora span:nth-child(1) { inset-inline-start: 4%;  inset-block-start: 8%;  background: radial-gradient(circle, rgba(23, 178, 168, .85), transparent 65%); }
.landing__aurora span:nth-child(2) { inset-inline-end: 2%;    inset-block-start: 2%;  background: radial-gradient(circle, rgba(43, 97, 178, .9), transparent 65%); animation-delay: -9s; animation-duration: 32s; }
.landing__aurora span:nth-child(3) { inset-inline-start: 26%; inset-block-end: -6%; background: radial-gradient(circle, rgba(109, 94, 252, .75), transparent 65%); animation-delay: -17s; animation-duration: 38s; }

@keyframes aurora-drift {
    from { transform: translate3d(0, 0, 0) scale(1); }
    to   { transform: translate3d(4%, -6%, 0) scale(1.18); }
}

/* بافت دانه‌ای برای جلوگیری از پله‌پله‌شدن گرادیان */
.landing::after {
    content: '';
    position: fixed;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    opacity: .035;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ــــ پنل شیشه‌ای ــــ */
.landing__panel {
    position: relative;
    z-index: 2;
    width: 100%;
    min-width: 0;
    max-width: 940px;
    padding: clamp(26px, 4vw, 46px);
    border-radius: 30px;
    background:
        linear-gradient(158deg, rgba(255, 255, 255, .13), rgba(255, 255, 255, .035) 46%, rgba(255, 255, 255, .06));
    border: 1px solid var(--line);
    box-shadow:
        0 44px 120px -36px rgba(2, 6, 18, .92),
        0 2px 0 rgba(255, 255, 255, .06) inset,
        0 -30px 80px -60px rgba(23, 178, 168, .5) inset;
    backdrop-filter: blur(28px) saturate(170%);
    -webkit-backdrop-filter: blur(28px) saturate(170%);
}

/* خط نورِ بالای پنل */
.landing__panel::before {
    content: '';
    position: absolute;
    inset-block-start: -1px;
    inset-inline: 12%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .85), transparent);
    opacity: .75;
}

/* ــــ سرصفحه: لوگو ــــ */
.landing__brand {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    text-align: center;
}

.landing__logo-wrap {
    position: relative;
    display: grid;
    place-items: center;
    isolation: isolate;
}

/* هاله‌ی نرم پشت لوگو تا سرمه‌ایِ نشان روی زمینه‌ی تیره گم نشود */
.landing__logo-wrap::before {
    content: '';
    position: absolute;
    z-index: -1;
    width: 168%;
    aspect-ratio: 1;
    border-radius: 50%;
    background: radial-gradient(circle,
        rgba(154, 199, 255, .26) 0%,
        rgba(96, 165, 250, .14) 34%,
        rgba(23, 178, 168, .10) 52%,
        transparent 70%);
    filter: blur(20px);
}

.landing__logo {
    display: block;
    height: clamp(116px, 15vw, 176px);
    width: auto;
    max-width: 100%;
    filter:
        drop-shadow(0 18px 34px rgba(4, 10, 22, .65))
        drop-shadow(0 0 26px rgba(120, 175, 255, .22));
}

.landing__title {
    margin: 14px 0 0;
    font-size: clamp(1.35rem, 2.6vw, 1.95rem);
    font-weight: 800;
    letter-spacing: -.2px;
    line-height: 1.4;
    background: linear-gradient(180deg, #ffffff 0%, #cdddf7 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.landing__subtitle {
    margin: 2px 0 0;
    font-size: clamp(.78rem, 1.5vw, .92rem);
    font-weight: 500;
    color: var(--fg-soft);
}

.landing__meta {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-block-start: 14px;
}

.chip {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    height: 30px;
    padding: 0 13px;
    font-size: 11.5px;
    font-weight: 600;
    color: var(--fg-soft);
    background: rgba(255, 255, 255, .05);
    border: 1px solid var(--line-soft);
    border-radius: 999px;
    backdrop-filter: blur(6px);
}

.chip i { font-size: 11px; opacity: .8; }
.chip--live { color: #7ff0e2; border-color: rgba(23, 178, 168, .34); background: rgba(23, 178, 168, .12); }

.chip--live::before {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #2ee6d6;
    box-shadow: 0 0 0 3px rgba(46, 230, 214, .18);
    animation: live-pulse 2.4s ease-in-out infinite;
}

@keyframes live-pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50%      { opacity: .45; transform: scale(.82); }
}

/* ــــ کارت‌های پرتال ــــ */
.landing__cards {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    margin-block-start: clamp(22px, 3vw, 32px);
}

.portal {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 24px 22px 20px;
    overflow: hidden;
    border-radius: 22px;
    text-decoration: none;
    color: var(--fg);
    background: linear-gradient(155deg, rgba(255, 255, 255, .1), rgba(255, 255, 255, .03));
    border: 1px solid var(--line);
    box-shadow: 0 18px 40px -30px rgba(0, 0, 0, .9);
    transition: transform .35s cubic-bezier(.2, .8, .3, 1), border-color .35s ease, box-shadow .35s ease, background .35s ease;
    isolation: isolate;
}

/* درخشش رنگی هر کارت */
.portal::before {
    content: '';
    position: absolute;
    inset-block-start: -60%;
    inset-inline-end: -30%;
    width: 80%;
    aspect-ratio: 1;
    border-radius: 50%;
    background: var(--glow, rgba(43, 97, 178, .55));
    filter: blur(48px);
    opacity: .5;
    z-index: -1;
    transition: opacity .35s ease, transform .5s ease;
}

/* درخشش عبوری هنگام هاور */
.portal::after {
    content: '';
    position: absolute;
    inset: 0;
    z-index: -1;
    background: linear-gradient(115deg, transparent 30%, rgba(255, 255, 255, .16) 48%, transparent 62%);
    transform: translateX(-130%);
    transition: transform .8s cubic-bezier(.2, .8, .3, 1);
}

.portal--org   { --glow: rgba(43, 97, 178, .62); }
.portal--staff { --glow: rgba(23, 178, 168, .62); }
.portal--site  { --glow: rgba(109, 94, 252, .62); }

.portal:hover,
.portal:focus-visible {
    transform: translateY(-5px);
    border-color: rgba(255, 255, 255, .28);
    background: linear-gradient(155deg, rgba(255, 255, 255, .16), rgba(255, 255, 255, .05));
    box-shadow: 0 30px 60px -32px rgba(0, 0, 0, .95), 0 0 0 1px rgba(255, 255, 255, .06) inset;
    color: var(--fg);
}

.portal:hover::before { opacity: .85; transform: scale(1.1); }
.portal:hover::after  { transform: translateX(130%); }

.portal__orb {
    display: grid;
    place-items: center;
    width: 54px;
    height: 54px;
    border-radius: 16px;
    font-size: 21px;
    color: #fff;
    background: linear-gradient(140deg, var(--orb-a), var(--orb-b));
    box-shadow: 0 12px 26px -12px var(--orb-b), 0 1px 0 rgba(255, 255, 255, .35) inset;
}

.portal--org   { --orb-a: #3f7fdc; --orb-b: #1c3f7d; }
.portal--staff { --orb-a: #23d3c4; --orb-b: #0c6f68; }
.portal--site  { --orb-a: #9a8bff; --orb-b: #5240c9; }

.portal__title {
    margin: 4px 0 0;
    font-size: 1.06rem;
    font-weight: 700;
    color: #fff;
}

.portal__desc {
    margin: 0;
    font-size: .79rem;
    line-height: 1.95;
    color: var(--fg-muted);
}

.portal__foot {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-block-start: auto;
    padding-block-start: 12px;
    font-size: 11.5px;
    font-weight: 600;
    color: var(--fg-soft);
}

.portal__cta {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 30px;
    padding: 0 12px;
    border-radius: 999px;
    font-size: 11.5px;
    font-weight: 700;
    color: #04121a;
    background: linear-gradient(135deg, #eaf2ff, #b9d3f6);
    transition: gap .25s ease;
}

.portal--staff .portal__cta { background: linear-gradient(135deg, #d9fff8, #8fe9dd); }
.portal--site .portal__cta  { background: linear-gradient(135deg, #f0ecff, #c6b8ff); }

.portal:hover .portal__cta { gap: 11px; }

.portal__hint {
    margin-inline-start: auto;
    font-size: 11px;
    font-weight: 500;
    color: var(--fg-muted);
}

/* ــــ پانوشت ــــ */
.landing__foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
    margin-block-start: 26px;
    padding-block-start: 16px;
    border-block-start: 1px solid var(--line-soft);
    font-size: 11.5px;
    color: var(--fg-muted);
}

.landing__links {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}

.landing__links a {
    color: var(--fg-soft);
    font-weight: 500;
    transition: color var(--transition);
}

.landing__links a:hover { color: #fff; }

.landing__sign {
    font-family: 'Times New Roman', Times, serif;
    font-weight: 700;
    font-size: 12.5px;
    letter-spacing: .3px;
    color: var(--fg-soft);
}

.landing__ver {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 3px 9px;
    border-radius: 999px;
    font-size: 10.5px;
    font-weight: 700;
    color: #9ff0e6;
    background: rgba(23, 178, 168, .12);
    border: 1px solid rgba(23, 178, 168, .3);
}

/* ــــ واکنش‌گرا ــــ */
@media (max-width: 720px) {
    .landing { padding-inline: 12px; }
    .landing__panel { border-radius: 24px; padding: 22px 18px; }
    .landing__cards { grid-template-columns: 1fr; gap: 12px; }
    .portal { padding: 18px 16px 16px; }
    .landing__foot { justify-content: center; text-align: center; }
    .landing__aurora { filter: blur(50px); opacity: .42; }
}

/* مرورگرهای بدون backdrop-filter */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
    .landing__panel { background: linear-gradient(158deg, rgba(16, 26, 46, .94), rgba(9, 16, 30, .96)); }
    .portal { background: linear-gradient(155deg, rgba(20, 32, 56, .96), rgba(12, 20, 36, .96)); }
}

@media (prefers-reduced-motion: reduce) {
    .landing__aurora span,
    .chip--live::before { animation: none; }
    .portal,
    .portal::before,
    .portal::after,
    .portal__cta { transition: none; }
}

@media print {
    .landing { background: #fff; color: #000; }
    .landing__aurora, .landing::after { display: none; }
}
