/* EXSEL: navy blazer, exam-paper white, foolscap rule blue, red-pen accent.
   One bold element: the SPM digit boxes. Everything else stays quiet. */
:root {
  --ink: #14192a;        /* logo navy */
  --ink-2: #232b47;
  --paper: #f8f9fb;      /* exam paper */
  --white: #ffffff;
  --rule: #d5dcea;       /* kertas kajang line */
  --red: #b3122e;        /* red pen */
  --red-ink: #8e0e25;
  --slate: #5a6275;
  --tint: #edf1f8;
  --wa: #168a47;
  --display: "Rokkitt", "Rockwell", Georgia, serif;
  --sans: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  --r: 4px;
  --ease-out: cubic-bezier(.2, .8, .2, 1);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 17px/1.6 var(--sans); }
a { color: var(--ink); text-decoration-color: var(--rule); text-decoration-thickness: 2px; text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--red); }
img { max-width: 100%; }
:focus-visible { outline: 3px solid var(--red); outline-offset: 2px; }
h1, h2 { font-family: var(--display); font-weight: 800; line-height: 1.05; margin: 0 0 .35em; letter-spacing: -.005em; }
h1 { font-size: clamp(2.25rem, 4.6vw, 3.25rem); }
h2 { font-size: 1.65rem; font-weight: 700; }
h3 { font-size: 1.06rem; font-weight: 700; margin: 0 0 .3em; line-height: 1.3; }
p { margin: 0 0 .8em; }
.prose { max-width: 68ch; overflow-wrap: anywhere; }
.prose p:last-child { margin-bottom: 0; }
.wrap { max-width: 1160px; margin: 0 auto; padding: 0 24px; }
.narrow { max-width: 820px; }
.muted { color: var(--slate); }
.small { font-size: .875rem; }
.mt { margin-top: 2.5rem; } .mt-s { margin-top: 1rem; }
.inline { display: inline; margin: 0; }
.opt { color: var(--slate); font-weight: 400; font-size: .88em; }
.danger { color: var(--red) !important; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
@media (max-width: 640px) { .wrap { padding: 0 16px; } body { font-size: 16px; } }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .45em; padding: .72em 1.2em; border-radius: var(--r);
  border: 1.5px solid transparent; font: 600 .95rem/1.2 var(--sans); cursor: pointer; text-decoration: none; white-space: nowrap;
  transition: background-color .15s, border-color .15s, transform .08s; }
.btn:active { transform: translateY(1px); }
.btn.is-busy { opacity: .6; pointer-events: none; cursor: progress; }
.btn-sm { padding: .48em .9em; font-size: .86rem; }
.btn-block { width: 100%; }
.btn-red { background: var(--red); color: var(--white); }
.btn-red:hover { background: var(--red-ink); }
.btn-navy { background: var(--ink); color: var(--white); }
.btn-navy:hover { background: var(--ink-2); }
.btn-ghost { background: var(--white); color: var(--ink); border-color: var(--rule); }
.btn-ghost:hover { border-color: var(--ink); }
.btn-ghost-light { color: var(--white); border-color: rgba(255,255,255,.4); background: transparent; }
.btn-ghost-light:hover { border-color: var(--white); }
.btn-wa { background: var(--wa); color: var(--white); }
.btn-wa:hover { background: #11743b; }
.linklike { background: none; border: 0; padding: 0; font: inherit; color: inherit; cursor: pointer; text-decoration: underline; text-decoration-color: var(--rule); text-decoration-thickness: 2px; text-underline-offset: 3px; }
.linklike:hover { text-decoration-color: var(--red); }

/* ---------- header ---------- */
.site-header { background: var(--ink); color: var(--white); position: sticky; top: 0; z-index: 20; view-transition-name: header; }
.header-inner { display: flex; align-items: center; gap: 20px; min-height: 66px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--white); text-decoration: none; }
.brand img { display: block; }
.brand strong { display: block; font: 800 1.35rem/1 var(--display); letter-spacing: .04em; }
.brand small { display: block; font-size: .75rem; opacity: .72; margin-top: 2px; }
.nav { margin-left: auto; display: flex; align-items: center; gap: 2px; }
.nav a, .nav .linklike { color: rgba(255,255,255,.82); text-decoration: none; padding: .5em .75em; font-size: .94rem; font-weight: 500; }
.nav a:hover, .nav .linklike:hover { color: var(--white); }
.nav a.active { color: var(--white); box-shadow: inset 0 -2px 0 var(--red); }
.nav a.btn-red { color: var(--white); margin-left: 6px; box-shadow: none; }
.nav-sep { width: 1px; height: 22px; background: rgba(255,255,255,.16); margin: 0 8px; }
.nav-user { display: inline-flex !important; align-items: center; gap: 8px; }
.nav-toggle, .nav-burger { display: none; }
@media (max-width: 860px) {
  .nav-burger { display: flex; flex-direction: column; gap: 5px; margin-left: auto; padding: 12px 6px; cursor: pointer; }
  .nav-burger span { width: 22px; height: 2px; background: var(--white); transition: transform .25s var(--ease-out), opacity .2s; }
  .nav-toggle:checked + .nav-burger span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-toggle:checked + .nav-burger span:nth-child(2) { opacity: 0; }
  .nav-toggle:checked + .nav-burger span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
  .nav { position: absolute; top: 66px; left: 0; right: 0; background: var(--ink); flex-direction: column; align-items: stretch;
    padding: 4px 16px 18px; border-top: 1px solid rgba(255,255,255,.08);
    clip-path: inset(0 0 100% 0); visibility: hidden; transition: clip-path .3s var(--ease-out), visibility 0s .3s; }
  .nav-toggle:checked ~ .nav { clip-path: inset(0 0 0 0); visibility: visible; transition: clip-path .3s var(--ease-out), visibility 0s; }
  .nav a, .nav .linklike { padding: .8em 0; text-align: left; }
  .nav a.active { box-shadow: inset 3px 0 0 var(--red); padding-left: 12px; }
  .nav-sep { width: auto; height: 1px; margin: 6px 0; }
  .nav a.btn-red { margin: 8px 0 0; }
}

.banner-pending { background: var(--tint); color: var(--ink); font-size: .92rem; padding: 10px 0; border-bottom: 1px solid var(--rule); }
.flash { margin: 18px 0 0; padding: 12px 16px; border-radius: var(--r); font-weight: 500; border-left: 4px solid; animation: flash-in .4s var(--ease-out); }
.flash-ok { background: #e7f4ec; color: #145c30; border-color: #1f8a4c; }
.flash-err { background: #fbe9ec; color: var(--red-ink); border-color: var(--red); }
@keyframes flash-in { from { opacity: 0; transform: translateY(-8px); } }

/* ---------- hero + SPM digit boxes ---------- */
.hero { background: var(--ink); color: var(--white); padding: clamp(48px, 9vw, 96px) 0 clamp(44px, 7vw, 72px); }
.yp-line { display: flex; flex-wrap: wrap; align-items: center; gap: .18em .32em; margin: 0; color: var(--white);
  font: 800 clamp(2.6rem, 9vw, 6.2rem)/1 var(--display); }
.hero-grid .yp-line { font-size: clamp(2.6rem, 6.4vw, 5rem); }
.batch-hero .yp-line { font-size: clamp(2.2rem, 7vw, 4.6rem); }
.digits { display: inline-flex; gap: .09em; cursor: text; border-radius: 6px; }
.digit { display: inline-block; width: .74em; height: 1.12em; background: var(--white); color: var(--ink); border-radius: 3px;
  overflow: hidden; text-align: center; box-shadow: inset 0 -.06em 0 var(--rule); }
.digits-static .digit { line-height: 1.12em; }
.strip { display: block; transform: translateY(calc(var(--d, 0) * -1.12em)); transition: transform .5s var(--ease-out); }
.strip span { display: block; height: 1.12em; line-height: 1.12em; }
.is-rolling .strip { transition-duration: 1.25s; }
.is-rolling .digit:nth-child(2) .strip { transition-delay: .1s; }
.is-rolling .digit:nth-child(3) .strip { transition-delay: .2s; }
.is-rolling .digit:nth-child(4) .strip { transition-delay: .3s; }
.yearpick:has(.yp-input:focus-visible) .digits { outline: 3px solid var(--red); outline-offset: 6px; }
.yp-input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.yp-controls { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 30px; }
.yp-step { width: 50px; height: 46px; border-radius: var(--r); border: 1.5px solid rgba(255,255,255,.35); background: transparent;
  color: var(--white); font: 600 1.5rem/1 var(--sans); cursor: pointer; transition: border-color .15s, background-color .15s; }
.yp-step:hover { border-color: var(--white); background: rgba(255,255,255,.06); }
.yp-step:active { background: rgba(255,255,255,.12); }
.hero-lede { margin: 34px 0 0; max-width: 34em; font-size: 1.12rem; color: rgba(255,255,255,.82); }
.hero-count { margin: 10px 0 0; color: rgba(255,255,255,.62); font-size: .95rem; }
.hero-count a { color: var(--white); text-decoration-color: var(--red); }
.hero-cta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }

/* ---------- sections ---------- */
.section { padding: 56px 0; }
.section-tint { background: var(--white); border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
main > .section:last-child { padding-bottom: 80px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.section-head h2 { margin: 0; }
.section-head a { font-weight: 600; font-size: .94rem; }
.two-col { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr); gap: 40px; }
@media (max-width: 900px) { .two-col { grid-template-columns: minmax(0, 1fr); } }

.ways { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px; }
.ways a { display: block; text-decoration: none; border-top: 3px solid var(--ink); padding-top: 18px; transition: border-color .2s; }
.ways a:hover { border-top-color: var(--red); }
.ways a:hover h2 { color: var(--red); }
.ways h2 { transition: color .2s; }
.ways p { color: var(--slate); max-width: 34ch; margin: 0; }
@media (max-width: 760px) { .ways { grid-template-columns: minmax(0, 1fr); gap: 28px; } }

.card { background: var(--white); border: 1px solid var(--rule); border-radius: var(--r); }
.pad { padding: 22px; }
.card + .card { margin-top: 16px; }

.ann-grid { display: grid; gap: 0; border-top: 1px solid var(--rule); }
.ann { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 8px 32px; padding: 20px 0; border-bottom: 1px solid var(--rule); }
.ann-date { font-weight: 700; color: var(--red); font-size: .95rem; grid-row: 1 / span 2; }
.ann h3, .ann .prose { grid-column: 2; }
@media (max-width: 640px) { .ann { grid-template-columns: minmax(0, 1fr); } .ann h3, .ann .prose { grid-column: 1; } .ann-date { grid-row: auto; } }

.cta-band { border-top: 1px solid var(--rule); }
.cta-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.cta-band p { color: var(--slate); margin: 0; }

/* ---------- page head ---------- */
.page-head { background: var(--ink); color: var(--white); padding: 44px 0 38px; }
.page-head h1 { color: var(--white); margin: 0 0 .2em; }
.page-head p { color: rgba(255,255,255,.75); margin: 0; max-width: 40em; }
.page-head-inner { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; flex-wrap: wrap; }

/* ---------- forms ---------- */
.form { display: grid; gap: 16px; }
.form label { display: grid; gap: 6px; font-weight: 600; font-size: .92rem; }
.form label:has(> .opt) { display: block; }
.form label:has(> .opt) > input, .form label:has(> .opt) > select { margin-top: 6px; }
.form label.check { display: flex; align-items: flex-start; gap: 10px; font-weight: 500; }
.form label.check input { margin-top: 5px; accent-color: var(--red); }
input, select, textarea { font: 400 1rem/1.4 var(--sans); color: var(--ink); background: var(--white); border: 1.5px solid var(--rule); border-radius: var(--r); padding: .68em .8em; width: 100%; min-width: 0; transition: border-color .15s; }
input[type=checkbox] { width: auto; }
input[type=file] { padding: .5em; background: var(--paper); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--ink); }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 2px solid var(--ink); outline-offset: 0; }
textarea { resize: vertical; }
.form-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; }
@media (max-width: 640px) { .form-row { grid-template-columns: minmax(0, 1fr); } }
.upload-preview { display: block; max-width: 220px; max-height: 180px; object-fit: cover; border-radius: var(--r); border: 1px solid var(--rule); margin-top: 8px;
  opacity: 0; transform: translateY(6px); transition: opacity .3s, transform .3s var(--ease-out); }
.upload-preview.is-in { opacity: 1; transform: none; }
.mini-search input { max-width: 300px; padding: .5em .75em; font-size: .94rem; }
.year-search { display: flex; gap: 8px; }
.year-search input { width: 220px; background: transparent; border-color: rgba(255,255,255,.3); color: var(--white); }
.year-search input::placeholder { color: rgba(255,255,255,.55); }
.year-search input:focus { border-color: var(--white); }
.filter-bar { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) minmax(0, 1fr) auto; gap: 10px; margin-bottom: 22px; }
@media (max-width: 760px) { .filter-bar { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } .filter-bar input { grid-column: 1 / -1; } }

.auth { display: grid; place-items: center; padding: 56px 16px 80px; }
.auth-card { width: 100%; max-width: 440px; background: var(--white); border: 1px solid var(--rule); border-top: 4px solid var(--ink); border-radius: var(--r); padding: 32px; }
.auth-card .form { margin-top: 20px; }
.auth-logo { display: block; margin-bottom: 14px; }

.note { background: var(--tint); border-left: 3px solid var(--ink); padding: 12px 16px; border-radius: 0 var(--r) var(--r) 0; margin-bottom: 18px; font-size: .94rem; }

details > summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center; }
details > summary::-webkit-details-marker { display: none; }
details > summary::after { content: "+"; font: 600 1.3rem/1 var(--sans); color: var(--slate); transition: transform .25s var(--ease-out); }
details[open] > summary::after { transform: rotate(45deg); }
@supports (interpolate-size: allow-keywords) {
  details { interpolate-size: allow-keywords; }
  details::details-content { block-size: 0; overflow: hidden; transition: block-size .3s var(--ease-out), content-visibility .3s allow-discrete; }
  details[open]::details-content { block-size: auto; }
}

/* ---------- chips / avatars ---------- */
.chip { display: inline-block; font-size: .76rem; font-weight: 600; padding: .18em .55em; border-radius: 3px; background: var(--tint); color: var(--slate); text-decoration: none; white-space: nowrap; }
.chip-batch { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1px var(--rule); }
.chip-gold { background: #f8e4e8; color: var(--red-ink); }
.status-pending { background: #fff1d1; color: #6d4f00; }
.status-active { background: #e2f3e8; color: #155f33; }
.status-banned { background: #f8e4e8; color: var(--red-ink); }
.chips { display: flex; gap: 6px; flex-wrap: wrap; margin: 6px 0 14px; }
.avatar { border-radius: 50%; object-fit: cover; flex-shrink: 0; display: inline-block; vertical-align: middle; }
.avatar-init { display: inline-grid; place-items: center; background: var(--ink); color: var(--white); font: 700 1rem/1 var(--display); letter-spacing: .02em; }

.empty { padding: 36px 22px; color: var(--slate); }
.empty svg { display: none; }
.empty h3 { color: var(--ink); }
.empty .btn { margin-top: 6px; }

/* ---------- forum ---------- */
.list-card { overflow: hidden; }
.thread-row { display: flex; gap: 14px; align-items: center; padding: 16px 20px; text-decoration: none; color: var(--ink); border-bottom: 1px solid var(--rule); transition: background-color .15s; }
.thread-row:last-child { border-bottom: 0; }
.thread-row:hover { background: var(--paper); }
.thread-row:hover .thread-title { color: var(--red); }
.thread-main { flex: 1; min-width: 0; }
.thread-title { font-weight: 600; margin-bottom: 4px; overflow-wrap: anywhere; transition: color .15s; }
.thread-title .pin { margin-right: 8px; vertical-align: 2px; }
.thread-meta { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; font-size: .84rem; color: var(--slate); }
.thread-stats { text-align: right; display: grid; font-size: .78rem; color: var(--slate); min-width: 76px; }
.thread-stats strong { font: 800 1.35rem/1 var(--display); color: var(--ink); }
@media (max-width: 560px) { .thread-row { padding: 14px 16px; } .thread-stats { min-width: 56px; } .thread-row > .avatar { display: none; } }

.forum-layout { display: grid; grid-template-columns: 230px minmax(0, 1fr); gap: 32px; align-items: start; }
.forum-side { position: sticky; top: 86px; display: grid; gap: 14px; }
.forum-side .mini-search input { max-width: none; }
.cat-nav { display: grid; }
.cat-nav a { display: flex; justify-content: space-between; padding: .55em .75em; text-decoration: none; font-weight: 500; font-size: .94rem; border-left: 3px solid transparent; }
.cat-nav a span { color: var(--slate); font-size: .84rem; }
.cat-nav a:hover { border-left-color: var(--rule); }
.cat-nav a.active { border-left-color: var(--red); font-weight: 700; background: var(--white); }
@media (max-width: 860px) {
  .forum-layout { grid-template-columns: minmax(0, 1fr); }
  .forum-side { position: static; }
  .cat-nav { display: flex; overflow-x: auto; gap: 4px; border-bottom: 1px solid var(--rule); }
  .cat-nav a { white-space: nowrap; gap: 8px; border-left: 0; border-bottom: 3px solid transparent; }
  .cat-nav a.active { border-bottom-color: var(--red); background: transparent; }
}
.back { display: table; font-size: .92rem; font-weight: 600; margin-bottom: 14px; }
.thread-h1 { font-size: clamp(1.8rem, 3.6vw, 2.5rem); overflow-wrap: anywhere; }
.posts .post { padding: 22px; border-bottom: 1px solid var(--rule); }
.posts .post:last-child { border-bottom: 0; }
.posts .post:target { animation: target-flash 1.6s var(--ease-out); }
@keyframes target-flash { from { background: #f8e4e8; } }
.post-op { border-left: 3px solid var(--ink); }
.post-head { display: flex; gap: 12px; align-items: center; margin-bottom: 12px; }
.post-author { font-weight: 700; text-decoration: none; }
.post-del { margin-left: auto; font-size: .86rem; }
.mod-bar { display: flex; gap: 16px; margin: -4px 0 14px; font-size: .9rem; }

/* ---------- batch index: a yearbook index of numerals ---------- */
.decade { margin-bottom: 40px; }
.decade-title { font-size: 1.35rem; border-bottom: 2px solid var(--ink); padding-bottom: 8px; margin-bottom: 0; }
.batch-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
.batch-card { padding: 16px 14px 14px; text-decoration: none; color: var(--ink); display: grid; gap: 1px; border-bottom: 1px solid var(--rule); border-right: 1px solid var(--rule); transition: background-color .15s; }
.batch-card:hover { background: var(--white); }
.batch-card:hover .batch-year { color: var(--red); }
.batch-year { font: 800 2.2rem/1 var(--display); transition: color .15s; width: fit-content; }
.batch-nick { font-size: .86rem; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.batch-count { font-size: .8rem; color: var(--slate); }
.batch-card.is-empty .batch-year { color: #a4abbc; }
.batch-card.is-empty .batch-nick { color: var(--slate); font-weight: 500; }

.batch-mini { overflow: hidden; }
.batch-mini-row { display: grid; grid-template-columns: 70px minmax(0, 1fr) auto; gap: 12px; align-items: baseline; padding: 12px 18px; text-decoration: none; color: var(--ink); border-bottom: 1px solid var(--rule); }
.batch-mini-row:last-child { border-bottom: 0; }
.batch-mini-row:hover .batch-mini-year { color: var(--red); }
.batch-mini-year { font: 800 1.5rem/1 var(--display); transition: color .15s; }
.batch-mini-name { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.batch-mini-n { font-size: .86rem; color: var(--slate); }

.batch-hero { --cover: none; background: linear-gradient(rgba(20,25,42,.8), rgba(20,25,42,.93)), var(--cover) center/cover, var(--ink); color: var(--white); padding: 34px 0 44px; }
.batch-hero .back { color: rgba(255,255,255,.75); text-decoration-color: rgba(255,255,255,.3); margin-bottom: 26px; }
.nick { font: 700 clamp(1.4rem, 3vw, 2rem)/1.2 var(--display); margin: 18px 0 0; }
.tagline { color: rgba(255,255,255,.8); font-size: 1.1rem; margin: 6px 0 0; }
.batch-hero-stats { display: flex; gap: 22px; flex-wrap: wrap; margin-top: 18px; color: rgba(255,255,255,.75); font-size: .96rem; }
.batch-hero-stats strong { color: var(--white); }
.batch-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 32px; align-items: start; }
.batch-main > .card { margin-bottom: 26px; }
.batch-side { display: grid; gap: 16px; }
.batch-side .card + .card { margin-top: 0; }
@media (max-width: 900px) { .batch-layout { grid-template-columns: minmax(0, 1fr); } .batch-side { order: -1; } }
.member-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 0; border-top: 1px solid var(--rule); }
.member { display: flex; gap: 12px; align-items: center; padding: 12px 4px; text-decoration: none; color: var(--ink); min-width: 0; border-bottom: 1px solid var(--rule); }
.member:hover strong { color: var(--red); }
.member div { display: grid; min-width: 0; }
.member strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; transition: color .15s; }
.member span, .member small { font-size: .84rem; color: var(--slate); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.locked p { max-width: 52ch; }
.pending-box { border-left: 3px solid var(--red); }
.pending-row { display: flex; gap: 10px; align-items: center; padding: 12px 0; border-top: 1px solid var(--rule); flex-wrap: wrap; }
.pending-row > div { flex: 1; min-width: 180px; }
.rep-row { display: flex; justify-content: space-between; padding: 8px 0; border-bottom: 1px solid var(--rule); font-size: .94rem; }
.side-nav { display: flex; justify-content: space-between; margin-top: 10px; }
.side-info a { font-size: .92rem; font-weight: 600; }

/* ---------- niaga ---------- */
.listing-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 20px; }
.listing-card { background: var(--white); border: 1px solid var(--rule); border-radius: var(--r); overflow: hidden; text-decoration: none; color: var(--ink); display: flex; flex-direction: column; transition: border-color .15s; }
.listing-card:hover { border-color: var(--ink); }
.listing-card:hover .listing-title { color: var(--red); }
.listing-card.is-sold { opacity: .6; }
.listing-img { aspect-ratio: 4 / 3; background: var(--tint); position: relative; }
.listing-img > img { width: 100%; height: 100%; object-fit: cover; display: block; }
.listing-noimg { width: 100%; height: 100%; display: grid; place-items: center; background: var(--ink-2); }
.listing-noimg img { width: 30%; opacity: .35; }
.listing-noimg.big { aspect-ratio: 4 / 3; border-radius: var(--r); }
.kind { position: absolute; top: 10px; left: 10px; font-size: .74rem; font-weight: 700; padding: .25em .6em; border-radius: 3px; background: var(--white); color: var(--ink); }
.kind-perkhidmatan { background: var(--tint) !important; color: var(--ink) !important; }
.kind-cari { background: #f8e4e8 !important; color: var(--red-ink) !important; }
.listing-body { padding: 14px 16px 16px; display: grid; gap: 3px; flex: 1; align-content: start; }
.listing-price { font: 800 1.35rem/1.15 var(--display); }
.listing-title { font-weight: 600; line-height: 1.35; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; transition: color .15s; }
.listing-meta { font-size: .82rem; color: var(--slate); }
.listing-seller { display: flex; gap: 8px; align-items: center; font-size: .82rem; color: var(--slate); margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--rule); }
.listing-seller .avatar-init { font-size: 9px !important; }
.listing-detail { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 40px; align-items: start; }
.listing-detail-img img { width: 100%; border-radius: var(--r); display: block; }
.listing-detail h1 { font-size: clamp(1.8rem, 3.2vw, 2.5rem); overflow-wrap: anywhere; }
.price-big { font: 800 2.2rem/1.1 var(--display); margin-bottom: 10px; }
.seller-box { display: flex; gap: 12px; align-items: center; padding: 16px 0; border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); margin: 22px 0 16px; }
.seller-box a { text-decoration: none; }
.row-actions { display: flex; gap: 8px; flex-wrap: wrap; }
@media (max-width: 820px) { .listing-detail { grid-template-columns: minmax(0, 1fr); gap: 22px; } }

/* ---------- profile / admin ---------- */
.profile-card { display: flex; gap: 24px; padding: 28px; align-items: flex-start; }
@media (max-width: 560px) { .profile-card { flex-direction: column; } }
.avatar-edit { display: flex; gap: 16px; align-items: center; }
.avatar-edit label { flex: 1; }
.tabs { display: flex; gap: 2px; margin-bottom: 16px; flex-wrap: wrap; border-bottom: 1px solid var(--rule); }
.tabs a { padding: .55em 1em; text-decoration: none; font-weight: 600; font-size: .92rem; border-bottom: 3px solid transparent; margin-bottom: -1px; }
.tabs a span { color: var(--slate); font-weight: 500; }
.tabs a.active { border-bottom-color: var(--red); }
.table-wrap { overflow-x: auto; margin-top: 14px; }
.table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.table th { text-align: left; font-size: .84rem; font-weight: 600; color: var(--slate); padding: 12px 14px; border-bottom: 2px solid var(--ink); }
.table td { padding: 12px 14px; border-bottom: 1px solid var(--rule); vertical-align: top; }
.admin-actions { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; min-width: 360px; }
.sel-sm { width: auto; padding: .35em .5em; font-size: .86rem; }
.ann-admin form { margin-top: 8px; }

.pager { display: flex; justify-content: space-between; align-items: center; margin-top: 22px; color: var(--slate); font-size: .92rem; }

/* ---------- footer ---------- */
.site-footer { background: var(--ink); color: rgba(255,255,255,.72); padding: 40px 0 22px; }
.footer-inner { display: flex; justify-content: space-between; gap: 30px; flex-wrap: wrap; align-items: center; }
.footer-brand { display: flex; gap: 16px; align-items: center; max-width: 420px; }
.footer-brand p { margin: 0; font-size: .92rem; }
.footer-links { display: flex; gap: 22px; flex-wrap: wrap; }
.footer-links a { color: rgba(255,255,255,.85); text-decoration: none; font-size: .94rem; }
.footer-links a:hover { color: var(--white); text-decoration: underline; text-decoration-color: var(--red); }
.footer-bottom { margin-top: 28px; padding-top: 16px; border-top: 1px solid rgba(255,255,255,.1); font-size: .82rem; }


/* ---------- home: one chapter per batch, like a yearbook ---------- */
.chapters { border-top: 2px solid var(--ink); }
.chapter { border-bottom: 1px solid var(--rule); background: var(--paper); scroll-margin-top: 66px; }
.chapter:nth-child(even) { background: var(--white); }
.chapter.is-mine { box-shadow: inset 4px 0 0 var(--red); }
.chapter-inner { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 40px; padding-top: 44px; padding-bottom: 44px; align-items: start; }
.chapter-year { position: sticky; top: 90px; text-decoration: none; display: grid; gap: 10px; justify-items: start;
  font: 800 4.4rem/1 var(--display); }
.digits-ink .digit { background: var(--ink); color: var(--white); box-shadow: none; transition: background-color .15s; }
.chapter-year:hover .digit { background: var(--red); }
.chapter-mine { font: 700 .86rem/1 var(--sans); color: var(--red); }
.chapter-head h2 { font-size: 2rem; margin: 0; }
.chapter-head h2 a { text-decoration: none; }
.chapter-head h2 a:hover { color: var(--red); }
.chapter-tagline { margin: 6px 0 0; font-size: 1.08rem; }
.chapter-facts { margin: 6px 0 0; color: var(--slate); font-size: .95rem; }
.chapter-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 28px 40px; margin-top: 26px; }
.chapter-cols h3 { font-size: .9rem; color: var(--slate); font-weight: 600; margin: 0 0 6px; padding-bottom: 6px; border-bottom: 2px solid var(--ink); }
.chapter-threads, .chapter-listings { list-style: none; margin: 0; padding: 0; }
.chapter-threads li { padding: 10px 0; border-bottom: 1px solid var(--rule); display: grid; gap: 2px; }
.chapter-threads a { font-weight: 600; text-decoration: none; overflow-wrap: anywhere; }
.chapter-threads a:hover { color: var(--red); }
.chapter-threads span { font-size: .84rem; color: var(--slate); }
.chapter-listings li { border-bottom: 1px solid var(--rule); }
.chapter-listings a { display: flex; gap: 12px; align-items: center; padding: 8px 0; text-decoration: none; min-width: 0; }
.chapter-listings a:hover strong { color: var(--red); }
.chapter-listings img, .chapter-listings .noimg { width: 56px; height: 56px; border-radius: var(--r); object-fit: cover; flex-shrink: 0; background: var(--ink-2); }
.chapter-listings span { display: grid; min-width: 0; }
.chapter-listings strong { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; transition: color .15s; }
.chapter-listings small { font-size: .84rem; color: var(--slate); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chapter-quiet { color: var(--slate); margin: 22px 0 0; }
.chapter-link { display: inline-block; margin-top: 22px; font-weight: 600; }
@media (max-width: 860px) {
  .chapter-inner { grid-template-columns: minmax(0, 1fr); gap: 18px; padding-top: 32px; padding-bottom: 32px; }
  .chapter-year { position: static; font-size: 3.2rem; grid-auto-flow: column; align-items: center; justify-content: start; }
}
.quiet-years h2 { font-size: 1.35rem; }
.quiet-list { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.quiet-list a { font: 700 1.05rem/1 var(--display); color: #8a92a6; text-decoration: none; padding: .45em .6em; border: 1px solid var(--rule); border-radius: 3px; background: var(--white); transition: color .15s, border-color .15s; }
.quiet-list a:hover { color: var(--ink); border-color: var(--ink); }


/* ---------- registration progress: logo mosaic + seats ---------- */
.hero-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(260px, 400px); gap: 48px; align-items: center; }
.hero-mosaic { margin: 0; }
.mosaic { display: block; width: 100%; height: auto; }
.mosaic .t-e { fill: rgba(255,255,255,.06); }
.mosaic .t-eg { fill: rgba(255,255,255,.2); }
.mosaic .t-c { fill: #3a4568; }
.mosaic .t-g { fill: var(--white); }
.mosaic .t-me { fill: var(--red); }
.mosaic .t-c, .mosaic .t-g { animation: tile-in .45s var(--ease-out) both; animation-delay: calc(var(--i) * 4ms); transform-box: fill-box; transform-origin: center; }
.mosaic .t-ring { fill: none; stroke: var(--red); stroke-width: .32; animation: ring-in 1.2s var(--ease-out) .5s both; transform-box: fill-box; transform-origin: center; }
@keyframes ring-in { from { opacity: 0; transform: scale(2.4); } }
.mosaic .t-me { animation: tile-me 1.8s var(--ease-out) .6s both; }
@keyframes tile-in { from { opacity: 0; transform: scale(.3); } }
@keyframes tile-me { 0% { opacity: 0; transform: scale(3); } 35% { opacity: 1; transform: scale(1); } 55% { transform: scale(1.5); } 100% { transform: scale(1); } }
.hero-mosaic figcaption { display: flex; gap: 14px; align-items: baseline; margin-top: 18px; color: rgba(255,255,255,.75); font-size: .95rem; }
.mc-num { font: 800 2.6rem/1 var(--display); color: var(--white); }
.mc-text a { color: var(--white); text-decoration-color: var(--red); font-weight: 600; }
.yp-alt { margin: 14px 0 0; font-size: .95rem; }
.yp-alt a { color: rgba(255,255,255,.8); text-decoration-color: rgba(255,255,255,.3); }
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: minmax(0, 1fr); gap: 36px; }
  .hero-mosaic { max-width: 320px; }
}

.seats { display: flex; flex-wrap: wrap; gap: 3px; max-width: 560px; }
.seat { width: 11px; height: 11px; border-radius: 2px; background: transparent; box-shadow: inset 0 0 0 1.5px var(--rule); }
.seat.is-on { background: var(--ink); box-shadow: none; }
.seat-next { box-shadow: inset 0 0 0 1.5px var(--red); }
.seats-text { margin: 8px 0 0; font-size: .92rem; color: var(--slate); }
.seats-text strong { color: var(--ink); }
.chapter-seats { margin-top: 18px; padding: 16px 0; border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.chapter-share { display: inline-block; margin-top: 10px; font-weight: 600; font-size: .94rem; text-decoration-color: var(--red); }
.batch-seats { margin-top: 20px; }
.batch-seats .seat { box-shadow: inset 0 0 0 1.5px rgba(255,255,255,.25); }
.batch-seats .seat.is-on { background: var(--white); box-shadow: none; }
.batch-seats .seat-next { box-shadow: inset 0 0 0 1.5px var(--red); }
.batch-seats .seats-text { color: rgba(255,255,255,.75); }
.batch-seats .seats-text strong { color: var(--white); }

.signup { padding: 48px 0 80px; }
.signup-grid { display: grid; grid-template-columns: minmax(0, 460px) minmax(0, 380px); gap: 56px; justify-content: center; align-items: start; }
.signup-card { background: var(--white); border: 1px solid var(--rule); border-top: 4px solid var(--ink); border-radius: var(--r); padding: 32px; }
.signup-card h1 { font-size: 2.3rem; }
.signup-card .form { margin-top: 20px; }
.signup-preview { position: sticky; top: 96px; background: var(--ink); color: var(--white); border-radius: var(--r); padding: 28px; }
.signup-preview .mosaic .t-me { animation-name: tile-wait; animation-duration: 1.6s; animation-iteration-count: infinite; animation-delay: 0s; }
@keyframes tile-wait { 50% { opacity: .25; } }
.sp-main { margin: 20px 0 6px; font-size: 1.05rem; }
.sp-main strong { color: var(--white); }
.sp-batch { margin: 0; color: rgba(255,255,255,.75); }
.sp-batch.is-new { animation: flash-in .35s var(--ease-out); }
@media (max-width: 860px) { .signup-grid { grid-template-columns: minmax(0, 1fr); gap: 24px; } .signup-preview { position: static; order: -1; padding: 20px; display: grid; grid-template-columns: 110px minmax(0,1fr); gap: 4px 18px; align-items: center; } .signup-preview .mosaic { grid-row: span 2; } .sp-main { margin: 0; font-size: .98rem; } .sp-batch { font-size: .9rem; } }

.welcome { background: var(--ink); color: var(--white); padding: clamp(48px, 8vw, 88px) 0; }
.welcome-grid { display: grid; grid-template-columns: minmax(240px, 380px) minmax(0, 1fr); gap: 56px; align-items: center; }
.welcome h1 { color: var(--white); font-size: clamp(2.4rem, 5vw, 3.6rem); }
.welcome-lede { font-size: 1.15rem; color: rgba(255,255,255,.85); margin-bottom: 22px; }
.welcome .seat { box-shadow: inset 0 0 0 1.5px rgba(255,255,255,.25); }
.welcome .seat.is-on { background: var(--white); box-shadow: none; }
.welcome .seats-text, .welcome .muted { color: rgba(255,255,255,.7); }
.welcome .seats-text strong { color: var(--white); }
.welcome .btn-ghost { background: transparent; color: var(--white); border-color: rgba(255,255,255,.4); }
@media (max-width: 860px) { .welcome-grid { grid-template-columns: minmax(0, 1fr); gap: 28px; } .welcome-mosaic { max-width: 260px; } }

/* ---------- page-to-page motion ---------- */
@view-transition { navigation: auto; }
::view-transition-old(root) { animation: vt-out .18s ease-in both; }
::view-transition-new(root) { animation: vt-in .28s var(--ease-out) both; }
::view-transition-group(*) { animation-duration: .38s; animation-timing-function: var(--ease-out); }
@keyframes vt-out { to { opacity: 0; } }
@keyframes vt-in { from { opacity: 0; transform: translateY(6px); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after, ::view-transition-group(*), ::view-transition-old(*), ::view-transition-new(*) {
    animation-duration: .01ms !important; animation-delay: 0s !important; transition-duration: .01ms !important; transition-delay: 0s !important;
  }
  @view-transition { navigation: none; }
}
