/* =====================================================================
   University of Delhi – Digital Degree (student pages)
   White, full-width layout. Deep DU ink for text and footer; seal red only for the main action.
   ===================================================================== */
:root {
    --ink: #1b1446;          /* text, headings, footer */
    --ink-2: #3d356b;
    --muted: #5f5a78;
    --line: #e4e1ee;
    --tint: #f4f2f8;         /* inputs, small highlights */
    --seal: #b0222c;         /* primary action */
    --seal-dark: #8e1a23;
    --ok: #17703f;  --ok-bg: #e6f4ec;
    --warn: #845400; --warn-bg: #fff3dc;
    --err: #b3261e; --err-bg: #fdecea;
    --shell: 1440px;
    --gutter: clamp(16px, 4vw, 64px);
    --font: "Mukta", "Nirmala UI", "Segoe UI", Arial, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
    margin: 0; font-family: var(--font); font-size: 17px; line-height: 1.6; color: var(--ink);
    background: #fff; min-height: 100vh; display: flex; flex-direction: column;
}
main { flex: 1; width: 100%; }
a { color: var(--ink-2); }
h1, h2, h3 { line-height: 1.15; margin: 0; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible {
    outline: 3px solid #6d5fd0; outline-offset: 2px;
}
.dd-shell { width: 100%; max-width: var(--shell); margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }
.dd-wrap { width: 100%; max-width: var(--shell); margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }
.dd-skip { position: absolute; left: -9999px; top: 0; background: var(--ink); color: #fff; padding: 10px 16px; z-index: 10; }
.dd-skip:focus { left: 8px; top: 8px; }

/* ---------------- top bar + header */
.dd-topbar { background: var(--ink); color: #d9d5ee; font-size: 14px; }
.dd-topbar__inner { display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: 38px; }
.dd-topbar nav { display: flex; gap: 22px; }
.dd-topbar a { color: #fff; text-decoration: none; }
.dd-topbar a:hover { text-decoration: underline; }

.dd-header { background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 5; }
.dd-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; min-height: 84px; }
.dd-brand { display: flex; align-items: center; gap: 14px; text-decoration: none; color: var(--ink); }
.dd-brand img { width: 54px; height: 54px; object-fit: contain; }
.dd-brand__text { display: flex; flex-direction: column; }
.dd-brand__name { font-size: 22px; font-weight: 800; letter-spacing: -0.01em; line-height: 1.1; }
.dd-brand__hi { font-size: 15px; color: var(--muted); line-height: 1.3; }
.dd-nav { display: flex; align-items: center; gap: 30px; }
.dd-nav a:not(.dd-btn) { color: var(--ink); text-decoration: none; font-weight: 600; font-size: 16px; padding: 6px 0; border-bottom: 2px solid transparent; }
.dd-nav a:not(.dd-btn):hover { border-bottom-color: var(--ink); }

/* ---------------- buttons */
.dd-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    font-family: var(--font); font-size: 17px; font-weight: 700; line-height: 1.2;
    padding: 13px 26px; border-radius: 6px; border: 2px solid transparent;
    cursor: pointer; text-decoration: none; transition: background-color .15s ease, border-color .15s ease, color .15s ease;
}
.dd-btn--sm { font-size: 15px; padding: 9px 18px; }
.dd-nav .dd-btn { white-space: nowrap; }
.dd-btn--lg { font-size: 18px; padding: 16px 30px; }
.dd-btn--primary { background: var(--seal); color: #fff; }
.dd-btn--primary:hover { background: var(--seal-dark); color: #fff; }
.dd-btn--ink { background: var(--ink); color: #fff; }
.dd-btn--ink:hover { background: #0f0a30; color: #fff; }
.dd-btn--outline { background: #fff; border-color: var(--ink); color: var(--ink); }
.dd-btn--outline:hover { background: var(--ink); color: #fff; }
.dd-btn--ghost { background: #fff; border-color: var(--line); color: var(--ink); }
.dd-btn--ghost:hover { border-color: var(--ink-2); }
.dd-btn--block { width: 100%; }
.dd-btn[disabled] { opacity: .55; cursor: not-allowed; }

/* ---------------- landing: hero */
.dd-hero { background: #fff; border-bottom: 1px solid var(--line); }
.dd-hero__grid {
    display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(320px, .8fr); gap: clamp(32px, 6vw, 96px);
    align-items: center; padding-top: clamp(48px, 7vw, 104px); padding-bottom: clamp(48px, 7vw, 104px);
}
.dd-hero h1 { font-size: clamp(40px, 5.6vw, 76px); font-weight: 800; letter-spacing: -0.025em; line-height: 1.02; max-width: 16ch; }
.dd-hero__hi { font-size: clamp(22px, 2.6vw, 32px); font-weight: 600; color: var(--ink-2); margin: 18px 0 0; }
.dd-hero__lede { font-size: clamp(17px, 1.5vw, 20px); color: var(--muted); max-width: 52ch; margin: 22px 0 36px; }
.dd-hero__actions { display: flex; flex-wrap: wrap; gap: 14px; }

.dd-ready { border: 1px solid var(--line); border-top: 6px solid var(--seal); border-radius: 8px; padding: 30px 30px 32px; background: #fff; box-shadow: 0 18px 40px -24px rgba(27, 20, 70, .35); }
.dd-ready h2 { font-size: 26px; font-weight: 800; }
.dd-ready > p { color: var(--muted); margin: 6px 0 18px; }
.dd-ready__list { list-style: none; margin: 0 0 26px; padding: 0; }
.dd-ready__list li { display: flex; gap: 14px; align-items: flex-start; padding: 12px 0; border-top: 1px solid var(--line); font-size: 16px; line-height: 1.45; }
.dd-ready__list li:last-child { border-bottom: 1px solid var(--line); }
.dd-ready__list strong { display: block; color: var(--ink); }
.dd-ready__list span { color: var(--muted); }
.dd-ready__icon { flex: none; width: 38px; height: 38px; border-radius: 8px; background: var(--tint); display: grid; place-items: center; }
.dd-ready__icon svg { width: 22px; height: 22px; fill: none; stroke: var(--ink); stroke-width: 1.7; stroke-linejoin: round; stroke-linecap: round; }

/* ---------------- landing: assurance row */
.dd-assure { border-bottom: 1px solid var(--line); }
.dd-assure__grid { display: grid; grid-template-columns: repeat(3, 1fr); }
.dd-assure__grid > div { padding: 30px 32px 30px 0; }
.dd-assure__grid > div + div { padding-left: 32px; border-left: 1px solid var(--line); }
.dd-assure h3 { font-size: 20px; font-weight: 800; }
.dd-assure p { margin: 4px 0 0; color: var(--muted); font-size: 16px; }

/* ---------------- landing: sections */
.dd-section { padding: clamp(56px, 7vw, 96px) 0; }
.dd-section--rule { border-top: 1px solid var(--line); }
.dd-section__head { margin-bottom: 40px; }
.dd-section__head h2 { font-size: clamp(30px, 3.4vw, 44px); font-weight: 800; letter-spacing: -0.02em; }
.dd-section__head p { color: var(--muted); font-size: 18px; margin: 10px 0 0; }

.dd-steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px; counter-reset: s; }
.dd-steps li { position: relative; padding-top: 26px; }
.dd-steps li::before { content: ""; position: absolute; top: 25px; left: 56px; right: -28px; height: 2px; background: var(--line); }
.dd-steps li:last-child::before { display: none; }
.dd-steps__no {
    position: relative; display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%;
    background: var(--ink); color: #fff; font-size: 22px; font-weight: 800; margin-top: -26px;
}
.dd-steps h3 { font-size: 21px; font-weight: 800; margin: 20px 0 6px; }
.dd-steps p { margin: 0; color: var(--muted); font-size: 16px; }

.dd-guidelines { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.4fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.dd-guidelines .dd-section__head { margin-bottom: 0; position: sticky; top: 110px; }
.dd-guidelines__list { list-style: none; margin: 0; padding: 0; }
.dd-guidelines__list li { position: relative; padding: 16px 0 16px 34px; border-bottom: 1px solid var(--line); font-size: 17px; }
.dd-guidelines__list li:first-child { border-top: 1px solid var(--line); }
.dd-guidelines__list li::before { content: ""; position: absolute; left: 4px; top: 25px; width: 10px; height: 10px; border-radius: 50%; border: 2px solid var(--seal); }

.dd-support { border-top: 1px solid var(--line); background: var(--tint); }
.dd-support__inner { display: flex; justify-content: space-between; align-items: center; gap: 32px; flex-wrap: wrap; padding-top: 44px; padding-bottom: 44px; }
.dd-support h2 { font-size: 26px; font-weight: 800; }
.dd-support p { margin: 6px 0 0; color: var(--muted); }
.dd-support__contact { font-weight: 600; color: var(--ink) !important; max-width: 46ch; margin: 0 !important; }

/* ---------------- student flow pages (Verify, OTP, Pay, Download) */
.dd-page {
    display: grid; grid-template-columns: minmax(240px, 300px) minmax(0, 1fr); gap: clamp(28px, 5vw, 80px);
    align-items: start; padding-top: clamp(36px, 5vw, 64px); padding-bottom: clamp(48px, 6vw, 88px);
}
.dd-page:not(:has(.dd-progress)) { grid-template-columns: minmax(0, 1fr); }
.dd-panel { max-width: 760px; background: #fff; }
.dd-panel--wide { max-width: 980px; }
.dd-panel h1 { font-size: clamp(32px, 3.4vw, 46px); font-weight: 800; letter-spacing: -0.02em; margin: 0 0 8px; }
.dd-panel__sub { color: var(--muted); font-size: 18px; margin: 0 0 30px; max-width: 60ch; }

.dd-progress { list-style: none; margin: 0; padding: 22px 0 0; position: sticky; top: 110px; }
.dd-progress li { position: relative; display: flex; gap: 14px; padding-bottom: 26px; color: var(--muted); }
.dd-progress li::before { content: ""; position: absolute; left: 17px; top: 38px; bottom: 2px; width: 2px; background: var(--line); }
.dd-progress li:last-child::before { display: none; }
.dd-progress__dot {
    flex: none; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center;
    border: 2px solid var(--line); background: #fff; font-weight: 800; font-size: 16px; color: var(--muted);
}
.dd-progress__text { display: flex; flex-direction: column; padding-top: 5px; line-height: 1.35; }
.dd-progress__text strong { font-size: 16.5px; color: var(--muted); }
.dd-progress__text span { font-size: 14px; }
.dd-progress li.is-done .dd-progress__dot { background: var(--ink); border-color: var(--ink); color: #fff; }
.dd-progress li.is-done::before { background: var(--ink); }
.dd-progress li.is-done strong { color: var(--ink); }
.dd-progress li.is-current .dd-progress__dot { border-color: var(--seal); color: var(--seal); box-shadow: 0 0 0 4px #f6dfe1; }
.dd-progress li.is-current strong { color: var(--ink); }

.dd-field { margin-bottom: 22px; max-width: 520px; }
.dd-field label { display: block; font-weight: 700; font-size: 16px; margin-bottom: 7px; }
.dd-field .req { color: var(--seal); }
.dd-input, .dd-select {
    width: 100%; font: inherit; font-size: 17px; padding: 13px 15px; border: 1.5px solid #cfcadf;
    border-radius: 6px; background: #fff; color: var(--ink);
}
.dd-input:hover, .dd-select:hover { border-color: #a9a2c4; }
.dd-input:focus, .dd-select:focus { border-color: var(--ink); outline: none; box-shadow: 0 0 0 3px rgba(109, 95, 208, .22); }
.dd-input--otp { letter-spacing: .5em; font-size: 28px; text-align: center; font-weight: 700; }
.dd-help { font-size: 14.5px; color: var(--muted); margin-top: 6px; }
.dd-error-text { color: var(--err); font-size: 14.5px; margin-top: 5px; display: block; }
.dd-panel form .dd-btn--block { max-width: 520px; }

.dd-alert { border-radius: 6px; padding: 14px 16px; margin-bottom: 24px; font-size: 16px; border-left: 4px solid; max-width: 760px; }
.dd-alert--ok { background: var(--ok-bg); color: var(--ok); }
.dd-alert--err { background: var(--err-bg); color: var(--err); }
.dd-alert--warn { background: var(--warn-bg); color: var(--warn); }

.dd-facts { display: grid; grid-template-columns: 190px 1fr; margin: 0 0 30px; max-width: 760px; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.dd-facts dt, .dd-facts dd { margin: 0; padding: 12px 18px; border-bottom: 1px solid var(--line); }
.dd-facts dt { background: var(--tint); color: var(--muted); font-size: 15px; }
.dd-facts dd { font-weight: 700; overflow-wrap: anywhere; }
.dd-panel--wide .dd-facts { max-width: none; }
.dd-facts dt:last-of-type, .dd-facts dd:last-of-type { border-bottom: 0; }

.dd-amount { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; border-top: 2px solid var(--ink); padding-top: 18px; margin: 4px 0 26px; max-width: 760px; }
.dd-amount span { font-size: 18px; color: var(--muted); }
.dd-amount strong { font-size: 40px; font-weight: 800; letter-spacing: -0.02em; }
.dd-row { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.dd-row--between { justify-content: space-between; }
.dd-link-btn { background: none; border: 0; padding: 0; color: var(--ink-2); text-decoration: underline; font: inherit; font-weight: 600; cursor: pointer; }
.dd-link-btn[disabled] { color: var(--muted); text-decoration: none; cursor: default; }

.dd-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 8px; }
.dd-action { border: 1px solid var(--line); border-top: 4px solid var(--ink); border-radius: 8px; padding: 24px; background: #fff; }
.dd-action h3 { margin: 0 0 6px; font-size: 21px; font-weight: 800; }
.dd-action p { margin: 0 0 18px; color: var(--muted); font-size: 16px; }
.dd-status { display: inline-block; font-size: 14px; font-weight: 700; padding: 2px 10px; border-radius: 20px; }
.dd-status--ok { background: var(--ok-bg); color: var(--ok); }
.dd-status--wait { background: var(--warn-bg); color: var(--warn); }

/* ---------------- footer */
.dd-footer { background: var(--ink); color: #cfcae6; font-size: 15.5px; }
.dd-footer a { color: #fff; text-decoration: none; }
.dd-footer a:hover { text-decoration: underline; }
.dd-footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1.2fr; gap: 40px; padding-top: 52px; padding-bottom: 36px; }
.dd-footer h2 { font-size: 17px; font-weight: 700; color: #fff; margin-bottom: 12px; }
.dd-footer ul { list-style: none; margin: 0; padding: 0; }
.dd-footer li { margin-bottom: 8px; }
.dd-footer p { margin: 0; }
.dd-footer__brand { display: flex; gap: 12px; align-items: center; color: #fff; font-weight: 800; font-size: 19px; line-height: 1.2; margin-bottom: 14px; }
.dd-footer__brand img { width: 46px; height: 46px; background: #fff; border-radius: 50%; padding: 3px; object-fit: contain; }
.dd-footer__hi { font-weight: 500; font-size: 14px; color: #cfcae6; }
.dd-footer__base { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-top: 18px; padding-bottom: 22px; border-top: 1px solid rgba(255, 255, 255, .14); font-size: 14px; }

/* ---------------- responsive */
@media (max-width: 1080px) {
    .dd-hero__grid { grid-template-columns: 1fr; }
    .dd-ready { max-width: 620px; }
    .dd-steps { grid-template-columns: 1fr 1fr; row-gap: 40px; }
    .dd-steps li:nth-child(2)::before { display: none; }
    .dd-guidelines { grid-template-columns: 1fr; }
    .dd-guidelines .dd-section__head { position: static; margin-bottom: 8px; }
}
@media (max-width: 860px) {
    .dd-nav a:not(.dd-btn) { display: none; }
    .dd-page { grid-template-columns: 1fr; gap: 20px; }
    .dd-progress { position: static; display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; padding: 0; }
    .dd-progress li { flex-direction: column; align-items: flex-start; gap: 6px; padding: 0; }
    /* horizontal connector between the step dots (mobile / tablet) */
    .dd-progress li::before { display: block; left: 34px; right: -2px; top: 14px; bottom: auto; width: auto; height: 2px; }
    .dd-progress li:last-child::before { display: none; }
    .dd-progress__dot { position: relative; z-index: 1; width: 30px; height: 30px; font-size: 14px; }
    .dd-progress__text { padding: 0; }
    .dd-progress__text strong { font-size: 13.5px; }
    .dd-progress__text span { display: none; }
    .dd-assure__grid { grid-template-columns: 1fr; }
    .dd-assure__grid > div, .dd-assure__grid > div + div { padding: 22px 0; border-left: 0; }
    .dd-assure__grid > div + div { border-top: 1px solid var(--line); }
    .dd-footer__grid { grid-template-columns: 1fr; gap: 26px; }
    .dd-actions { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
    body { font-size: 16px; }
    .dd-topbar__inner > span { display: none; }
    .dd-topbar__inner { justify-content: flex-end; }
    .dd-header__inner { min-height: 68px; }
    .dd-brand img { width: 42px; height: 42px; }
    .dd-brand__name { font-size: 18px; }
    .dd-brand__hi { font-size: 13px; }
    .dd-nav .dd-btn { padding: 8px 12px; font-size: 14px; }
    .dd-header__inner { gap: 10px; }
    .dd-brand { gap: 10px; }
    .dd-hero__actions .dd-btn { width: 100%; }
    .dd-ready { padding: 24px 20px; }
    /* "How it works" stacks vertically: number on the left, vertical connector down to the next number */
    .dd-steps { grid-template-columns: 1fr; gap: 0; row-gap: 0; }
    .dd-steps li { padding: 0 0 30px 70px; min-height: 52px; }
    .dd-steps__no { position: absolute; left: 0; top: 0; margin-top: 0; z-index: 1; }
    .dd-steps li::before, .dd-steps li:nth-child(2)::before { display: block; top: 52px; bottom: 0; left: 25px; right: auto; width: 2px; height: auto; }
    .dd-steps li:last-child { padding-bottom: 0; }
    .dd-steps li:last-child::before { display: none; }
    .dd-steps h3 { margin: 10px 0 6px; }
    .dd-facts { grid-template-columns: 1fr; }
    .dd-facts dt { border-bottom: 0; padding-bottom: 2px; }
    .dd-facts dd { padding-top: 4px; }
    .dd-amount strong { font-size: 32px; }
}
/* ---------------- download page: student heading with Sign out */
.dd-studenthead { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 16px; align-items: start; }
.dd-studenthead__name { grid-column: 1; overflow-wrap: anywhere; }
.dd-studenthead__out { grid-column: 2; margin: 8px 0 0; }
.dd-studenthead__sub { grid-column: 1 / -1; max-width: none; }
.dd-dl.is-busy { opacity: .75; cursor: progress; }
@media (max-width: 560px) {
    .dd-studenthead { column-gap: 12px; }
    .dd-studenthead__out { margin-top: 2px; }
    .dd-studenthead__out .dd-btn { padding: 7px 14px; font-size: 14px; }
    .dd-studenthead .dd-panel__sub { margin-bottom: 22px; }
}

/* ---------------- payment status / receipt */
.dd-receipt__status { display: flex; flex-wrap: wrap; gap: 10px 22px; align-items: center; margin: 0 0 26px; font-size: 16px; }
.dd-receipt__title { font-size: 19px; font-weight: 800; margin: 0 0 12px; }
.dd-print-only { display: none; }
@media print {
    .dd-topbar, .dd-header, .dd-footer, .dd-progress, .dd-no-print, .dd-skip { display: none !important; }
    .dd-print-only { display: block; }
    .dd-receipt__head { font-size: 18px; margin-bottom: 14px; padding-bottom: 10px; border-bottom: 2px solid #1f2a5c; }
    .dd-page { display: block; padding: 0; }
    .dd-panel { box-shadow: none; border: 0; padding: 0; max-width: none; }
    .dd-facts { break-inside: avoid; margin-bottom: 16px; }
    body { background: #fff; }
}

@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; animation: none !important; } }
