/* ============================================================
   ui.css — component & section styles
   ============================================================ */

/* ---------- NAV ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  transition: background .3s ease, border-color .3s ease, backdrop-filter .3s ease;
  border-bottom: 1px solid transparent;
}
.nav-scrolled {
  background: var(--nav-bg);
  backdrop-filter: blur(14px) saturate(1.2);
  border-bottom-color: var(--line-soft);
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.brand { display: flex; align-items: center; gap: 11px; }
.brand-mark { width: 13px; height: 13px; background: var(--accent); border-radius: 3px; transform: rotate(45deg); transition: transform .3s ease; }
.brand:hover .brand-mark { transform: rotate(135deg); }
.brand-name { font-family: var(--ff-display); font-weight: 800; font-size: 17px; letter-spacing: -0.01em; }
.nav-links { display: flex; gap: 28px; }
.nav-links a { font-family: var(--ff-mono); font-size: clamp(13px, 0.95vw, 15px); color: var(--muted); transition: color .2s; position: relative; }
.nav-links a:hover { color: var(--text); }
.nav-links a::after { content: ""; position: absolute; left: 0; bottom: -5px; width: 0; height: 1.5px; background: var(--accent); transition: width .25s ease; }
.nav-links a:hover::after { width: 100%; }
.nav-right { display: flex; align-items: center; gap: 14px; }
.nav-clock { font-family: var(--ff-mono); font-size: 12.5px; color: var(--text); display: inline-flex; align-items: center; gap: 7px; letter-spacing: 0.04em; white-space: nowrap; }
.nav-wx { display: inline-flex; align-items: center; gap: 5px; color: var(--text); font-family: var(--ff-mono); font-size: 12.5px; letter-spacing: 0.04em; }
.nav-wx svg { display: block; opacity: 0.92; }
.nav-wx-temp { color: var(--muted); }
@media (max-width: 620px) { .nav-wx-temp { display: none; } }
.clock-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 9px var(--accent); }
@media (max-width: 620px) { .nav-clock { display: none; } }
@media (max-width: 620px) { .nav-clock { display: none; } }

/* ---------- in-nav theme switcher ---------- */
.thememenu { position: relative; }
.thememenu-btn { display: inline-flex; align-items: center; gap: 8px; background: none; border: 1px solid var(--line); border-radius: 100px; padding: 7px 12px; font-family: var(--ff-mono); font-size: 12px; color: var(--text); transition: border-color .2s; }
.thememenu-btn:hover { border-color: var(--accent); }
.thememenu-chip { width: 13px; height: 13px; border-radius: 4px; flex: none; box-shadow: inset 0 0 0 1px rgba(0,0,0,0.25); }
.thememenu-cur { letter-spacing: 0.02em; }
.thememenu-caret { color: var(--faint); font-size: 10px; }
.thememenu-pop { position: absolute; top: calc(100% + 9px); right: 0; z-index: 60; min-width: 218px; background: var(--bg-1); border: 1px solid var(--line); border-radius: 14px; padding: 8px; box-shadow: 0 18px 50px -20px rgba(0,0,0,0.7); display: flex; flex-direction: column; gap: 2px; }
.thememenu-h { font-family: var(--ff-mono); font-size: 10px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--faint); padding: 6px 10px 8px; }
.thememenu-item { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; background: none; border: none; border-radius: 9px; padding: 9px 10px; font-family: var(--ff-body); font-size: 13.5px; color: var(--text); transition: background .15s; }
.thememenu-item:hover { background: var(--bg-2); }
.thememenu-item.on { background: var(--bg-2); color: var(--accent-text); font-weight: 600; }
@media (max-width: 620px) { .thememenu-cur { display: none; } }
.lang-toggle { background: none; border: 1px solid var(--line); border-radius: 100px; padding: 7px 13px; font-family: var(--ff-mono); font-size: 12px; color: var(--faint); display: flex; gap: 4px; transition: border-color .2s; }
.lang-toggle:hover { border-color: var(--line); }
.lang-toggle .on { color: var(--accent-text); }
.lang-sep { color: var(--line); }
@media (max-width: 880px) { .nav-links { display: none; } }

/* ---------- HERO ---------- */
.hero { min-height: 100vh; display: flex; align-items: center; padding-top: 90px; position: relative; }
.hero-grid { display: grid; grid-template-columns: 1fr; gap: 40px; align-items: center; }
.hero-split .hero-grid { grid-template-columns: 1.25fr 0.75fr; }
.hero-centered .hero-main { text-align: center; align-items: center; margin: 0 auto; }
.hero-centered .eyebrow { justify-content: center; }
.hero-centered .hero-cta, .hero-centered .hero-avail { justify-content: center; }
.hero-main { display: flex; flex-direction: column; align-items: flex-start; }
.hero-name {
  font-family: var(--ff-display); font-weight: 800;
  font-size: clamp(56px, 12vw, 158px); line-height: 0.86; letter-spacing: -0.035em;
  margin: 22px 0 0; text-wrap: balance;
}
.hero-tag { font-size: clamp(18px, 2.1vw, 25px); color: var(--muted); max-width: 28ch; margin: 26px 0 0; line-height: 1.4; }
.hero-centered .hero-tag { max-width: 36ch; }
.hero-cta { display: flex; gap: 13px; margin-top: 36px; flex-wrap: wrap; }
.hero-avail { display: flex; align-items: center; gap: 9px; margin-top: 28px; font-family: var(--ff-mono); font-size: 12.5px; color: var(--faint); letter-spacing: 0.03em; }
.hero-avail .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 0 var(--accent-glow); animation: pulse 2.4s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 var(--accent-glow); } 70% { box-shadow: 0 0 0 9px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }
.hero-side { aspect-ratio: 4/5; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line-soft); }
.hero-scroll { position: absolute; bottom: 34px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 10px; font-family: var(--ff-mono); font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--faint); }
.hero-scroll-line { width: 1px; height: 40px; background: linear-gradient(var(--accent), transparent); }
@media (max-width: 880px) { .hero-split .hero-grid { grid-template-columns: 1fr; } .hero-side { display: none; } }

/* ---------- COVER ART ---------- */
.cover { position: relative; width: 100%; height: 100%; overflow: hidden; display: grid; place-items: center; isolation: isolate; }
.cover-stripes { position: absolute; inset: 0; opacity: 0.5; }
.cover-blob { position: absolute; width: 46%; aspect-ratio: 1; border-radius: 46% 54% 60% 40% / 50% 44% 56% 50%; filter: blur(2px); right: -8%; top: -12%; mix-blend-mode: screen; opacity: 0.85; }
.cover-initials { font-family: var(--ff-display); font-weight: 800; color: oklch(1 0 0 / 0.94); letter-spacing: -0.04em; mix-blend-mode: overlay; z-index: 1; }

/* ---------- SECTION HEAD ---------- */
.sec-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 30px; margin-bottom: 52px; flex-wrap: wrap; }
.filters { display: flex; gap: 8px; flex-wrap: wrap; }
.filters button { font-family: var(--ff-mono); font-size: 12.5px; padding: 8px 15px; border-radius: 100px; border: 1px solid var(--line); background: transparent; color: var(--muted); transition: all .18s; }
.filters button:hover { color: var(--text); border-color: var(--line); }
.filters button.on { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); font-weight: 700; }

/* ---------- PROJECTS: cards ---------- */
.projects-cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 26px; }
.projects-cards .pcard-feat { grid-column: span 2; }
.pcard { background: var(--bg-1); border: 1px solid var(--line-soft); border-radius: var(--radius); overflow: hidden; position: relative; transition: transform .3s cubic-bezier(.2,.7,.2,1), border-color .3s, box-shadow .3s; }
.pcard:hover { transform: translateY(-5px); border-color: var(--line); box-shadow: 0 24px 60px -30px oklch(0 0 0 / 0.7); }
.pcard-cover { aspect-ratio: 16/9; }
.pcard-feat { display: grid; grid-template-columns: 1fr 1fr; }
.pcard-feat .pcard-cover { aspect-ratio: auto; height: 100%; min-height: 320px; }
.pcard-body { padding: 26px 28px 28px; }
.pcard-feat .pcard-body { display: flex; flex-direction: column; justify-content: center; padding: 40px; }
.pcard-meta { display: flex; align-items: center; gap: 12px; justify-content: space-between; }
.chip { font-family: var(--ff-mono); font-size: 11px; letter-spacing: 0.04em; color: var(--accent-text); border: 1px solid var(--accent); border-radius: 100px; padding: 4px 11px; white-space: nowrap; }
.pcard-period { font-family: var(--ff-mono); font-size: 11.5px; color: var(--faint); }
.pcard-title { font-family: var(--ff-display); font-weight: 800; font-size: clamp(22px, 2.6vw, 34px); letter-spacing: -0.02em; margin: 16px 0 0; line-height: 1.02; }
.pcard-tag { color: var(--muted); margin: 12px 0 0; font-size: 16px; }
.pcard-bullets { list-style: none; padding: 0; margin: 22px 0 0; display: flex; flex-direction: column; gap: 13px; }
.pcard-bullets li { position: relative; padding-left: 22px; font-size: clamp(15.5px, 1.05vw, 19px); color: var(--muted); line-height: 1.6; }
.pcard-bullets li::before { content: "▸"; position: absolute; left: 0; color: var(--accent-text); }
.pcard-foot { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 22px; flex-wrap: wrap; }
.tags { display: flex; flex-wrap: wrap; gap: 7px; }
.tags span { font-family: var(--ff-mono); font-size: 11px; color: var(--faint); background: var(--bg-2); border-radius: 6px; padding: 4px 9px; }
.pcard-cta { font-family: var(--ff-mono); font-size: 12.5px; color: var(--accent-text); white-space: nowrap; transition: gap .2s; }
.pcard-cta:hover { text-decoration: underline; }
@media (max-width: 760px) { .projects-cards { grid-template-columns: 1fr; } .projects-cards .pcard-feat { grid-column: auto; grid-template-columns: 1fr; } .pcard-feat .pcard-cover { min-height: 200px; } }

/* ---------- PROJECTS: rows ---------- */
.projects-rows { display: flex; flex-direction: column; }
.prow { display: grid; grid-template-columns: 70px 110px 1fr auto; gap: 26px; align-items: center; padding: 26px 8px; border-top: 1px solid var(--line-soft); position: relative; transition: padding .25s, background .25s; }
.prow:hover { background: var(--bg-1); padding-left: 18px; padding-right: 18px; }
.projects-rows .prow:last-child { border-bottom: 1px solid var(--line-soft); }
.prow-year { font-family: var(--ff-mono); font-size: 13px; color: var(--faint); }
.prow-cover { width: 110px; height: 72px; border-radius: var(--radius-sm); overflow: hidden; }
.prow-head { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.prow-body h3 { font-family: var(--ff-display); font-weight: 800; font-size: clamp(20px, 2.3vw, 28px); margin: 0; letter-spacing: -0.02em; }
.prow-body p { color: var(--muted); margin: 7px 0 11px; font-size: 15px; }
.prow-link { font-family: var(--ff-mono); font-size: 12.5px; color: var(--accent-text); white-space: nowrap; }
.prow-period { font-family: var(--ff-mono); font-size: 12px; color: var(--faint); white-space: nowrap; }
@media (max-width: 760px) { .prow { grid-template-columns: 1fr; gap: 12px; } .prow-cover { width: 100%; height: 140px; } .prow-year { display: none; } }

/* add-card (admin) */
.add-card { grid-column: 1 / -1; display: flex; align-items: center; justify-content: center; gap: 12px; min-height: 110px; border: 2px dashed var(--line); border-radius: var(--radius); background: transparent; color: var(--muted); font-family: var(--ff-mono); font-size: 14px; transition: all .2s; }
.add-card:hover { border-color: var(--accent); color: var(--accent-text); }
.add-plus { font-size: 26px; line-height: 1; }
.projects-rows .add-card { margin-top: 18px; }

/* ---------- ABOUT ---------- */
.about-grid { display: grid; grid-template-columns: 0.85fr 1.15fr; gap: 60px; align-items: start; }
.about-body { font-size: clamp(18px, 2vw, 23px); line-height: 1.55; color: var(--text); }
.about-meta { display: flex; gap: 50px; margin: 36px 0; flex-wrap: wrap; }
.about-meta .k { display: block; font-family: var(--ff-mono); font-size: 11px; text-transform: uppercase; letter-spacing: 0.15em; color: var(--faint); margin-bottom: 5px; }
.about-meta .v { font-size: clamp(16px, 1.05vw, 19px); color: var(--text); }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; border-top: 1px solid var(--line-soft); padding-top: 30px; margin-top: 10px; }
.stat-value { font-family: var(--ff-display); font-weight: 800; font-size: clamp(30px, 4vw, 48px); color: var(--accent-text); letter-spacing: -0.03em; }
.stat-label { font-family: var(--ff-mono); font-size: 11.5px; color: var(--faint); margin-top: 4px; }
@media (max-width: 880px) { .about-grid { grid-template-columns: 1fr; gap: 30px; } .stats { grid-template-columns: repeat(2, 1fr); } }

/* ---------- SKILLS ---------- */
.skill-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.skill-col { background: var(--bg-1); border: 1px solid var(--line-soft); border-radius: var(--radius); padding: 28px 24px; transition: border-color .25s, transform .25s; }
.skill-col:hover { border-color: var(--line); transform: translateY(-4px); }
.skill-col h4 { font-family: var(--ff-mono); font-size: clamp(12px, 0.9vw, 15px); text-transform: uppercase; letter-spacing: 0.16em; color: var(--accent-text); margin: 0 0 18px; }
.skill-col ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 11px; }
.skill-col li { font-size: clamp(15.5px, 1.05vw, 19px); color: var(--text); padding-bottom: 11px; border-bottom: 1px solid var(--line-soft); }
.skill-col li:last-child { border-bottom: none; padding-bottom: 0; }
@media (max-width: 880px) { .skill-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .skill-grid { grid-template-columns: 1fr; } }

/* ---------- EDUCATION ---------- */
.edu-grid { display: grid; grid-template-columns: 0.85fr 1.15fr; gap: 60px; align-items: start; }
.edu-item { display: grid; grid-template-columns: 130px 1fr; gap: 24px; padding: 28px 0; border-top: 1px solid var(--line-soft); }
.edu-item:last-child { border-bottom: 1px solid var(--line-soft); }
.edu-period { font-family: var(--ff-mono); font-size: clamp(13px, 0.95vw, 16px); color: var(--accent-text); }
.edu-main h3 { font-family: var(--ff-display); font-weight: 800; font-size: clamp(22px, 2.6vw, 30px); margin: 0; letter-spacing: -0.02em; }
.edu-degree { color: var(--text); margin: 8px 0 4px; font-size: clamp(16px, 1.05vw, 19px); }
.edu-note { color: var(--faint); font-family: var(--ff-mono); font-size: clamp(12.5px, 0.9vw, 15px); }
@media (max-width: 880px) { .edu-grid { grid-template-columns: 1fr; gap: 28px; } .edu-item { grid-template-columns: 1fr; gap: 8px; } }

/* ---------- EXPERIENCE / TIMELINE ---------- */
.timeline { position: relative; padding-left: 4px; }
.tl-item { display: grid; grid-template-columns: 150px 1fr; gap: 30px; padding: 26px 0 26px 30px; position: relative; border-left: 1px solid var(--line); }
.tl-item:last-child { border-left-color: transparent; }
.tl-dot { position: absolute; left: -6px; top: 32px; width: 11px; height: 11px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 4px var(--bg); }
.tl-period { font-family: var(--ff-mono); font-size: clamp(12.5px, 0.9vw, 15px); color: var(--faint); padding-top: 2px; }
.tl-body h3 { font-family: var(--ff-display); font-weight: 700; font-size: clamp(22px, 1.8vw, 30px); margin: 0; }
.tl-org { color: var(--accent-text); font-size: clamp(14px, 0.95vw, 16px); margin: 5px 0 9px; font-family: var(--ff-mono); }
.tl-body p { color: var(--muted); margin: 0; font-size: clamp(15.5px, 1.05vw, 19px); }
@media (max-width: 760px) { .tl-item { grid-template-columns: 1fr; gap: 8px; } }

/* ---------- CONTACT / FOOTER ---------- */
.contact { padding-bottom: 0; }
.contact-inner { text-align: center; display: flex; flex-direction: column; align-items: center; padding: 30px 0 90px; }
.contact-inner .eyebrow { justify-content: center; }
.contact-title { font-family: var(--ff-display); font-weight: 800; font-size: clamp(30px, 4.6vw, 56px); letter-spacing: -0.03em; line-height: 1.0; margin: 20px 0 0; text-wrap: balance; }
.contact-lead { color: var(--muted); max-width: 48ch; margin: 22px 0 0; font-size: clamp(17px, 1.15vw, 21px); }
.contact-actions { display: flex; gap: 13px; margin: 38px 0 0; flex-wrap: wrap; justify-content: center; }
.contact-email { font-family: var(--ff-mono); font-size: 14px; color: var(--faint); margin-top: 26px; }
.footer { border-top: 1px solid var(--line-soft); padding: 30px 0; }
.footer-inner { display: flex; justify-content: space-between; font-family: var(--ff-mono); font-size: 12px; color: var(--faint); flex-wrap: wrap; gap: 10px; }

/* ---------- ADMIN BAR ---------- */
.adminbar { position: fixed; right: 22px; bottom: 22px; z-index: 80; display: flex; flex-direction: column; align-items: flex-end; gap: 10px; }
.admin-toggle { display: inline-flex; align-items: center; gap: 9px; font-family: var(--ff-mono); font-size: 13px; padding: 13px 18px; border-radius: 100px; border: 1px solid var(--line); background: var(--bg-1); color: var(--text); box-shadow: 0 12px 40px -16px oklch(0 0 0 / 0.8); transition: all .2s; }
.admin-toggle:hover { border-color: var(--accent); }
.admin-toggle.on { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); font-weight: 700; }
.admin-icon { font-size: 15px; }
.adminbar-tools { display: flex; align-items: center; gap: 7px; background: var(--bg-1); border: 1px solid var(--line-soft); border-radius: 14px; padding: 9px; box-shadow: 0 16px 50px -20px oklch(0 0 0 / 0.85); flex-wrap: wrap; max-width: 320px; justify-content: flex-end; }
.adminbar-tools button { font-family: var(--ff-mono); font-size: 12px; padding: 8px 12px; border-radius: 9px; border: 1px solid var(--line-soft); background: var(--bg-2); color: var(--text); transition: all .18s; }
.adminbar-tools button:hover { border-color: var(--accent); color: var(--accent-text); }
.adminbar-tools button.danger:hover { border-color: oklch(0.65 0.2 25); color: oklch(0.75 0.2 25); }
.saved-dot { font-family: var(--ff-mono); font-size: 10.5px; color: var(--accent-text); width: 100%; text-align: right; }

/* card admin overlay */
.card-admin { position: absolute; top: 12px; right: 12px; z-index: 5; display: flex; gap: 6px; }
.card-admin button { font-family: var(--ff-mono); font-size: 11px; padding: 6px 11px; border-radius: 8px; border: none; background: oklch(0.18 0.01 264 / 0.9); color: var(--text); backdrop-filter: blur(6px); transition: all .15s; }
.card-admin button:hover { background: var(--accent); color: var(--accent-ink); }
.card-admin button.danger:hover { background: oklch(0.6 0.21 25); color: #fff; }
.is-admin .pcard, .is-admin .prow { outline: 1px dashed var(--line); outline-offset: 3px; }

/* ---------- MODAL ---------- */
.modal-backdrop { position: fixed; inset: 0; z-index: 100; background: oklch(0.1 0.01 264 / 0.7); backdrop-filter: blur(6px); display: grid; place-items: center; padding: 24px; animation: fade .2s ease; }
@keyframes fade { from { opacity: 0; } }
.modal { width: min(720px, 100%); max-height: 88vh; display: flex; flex-direction: column; background: var(--bg-1); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: 0 40px 100px -30px oklch(0 0 0 / 0.9); }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 22px 26px; border-bottom: 1px solid var(--line-soft); }
.modal-head h3 { font-family: var(--ff-display); font-weight: 700; font-size: 22px; margin: 0; }
.modal-x { background: none; border: none; color: var(--muted); font-size: 18px; padding: 6px; transition: color .2s; }
.modal-x:hover { color: var(--text); }
.modal-body { padding: 24px 26px; overflow-y: auto; display: flex; flex-direction: column; gap: 16px; }
.modal-foot { display: flex; justify-content: flex-end; gap: 12px; padding: 18px 26px; border-top: 1px solid var(--line-soft); }
.fld { display: flex; flex-direction: column; gap: 7px; flex: 1; }
.fld-label { font-family: var(--ff-mono); font-size: 11px; text-transform: uppercase; letter-spacing: 0.1em; color: var(--faint); }
.fld input, .fld textarea { background: var(--bg); border: 1px solid var(--line-soft); border-radius: 10px; padding: 11px 13px; color: var(--text); font-family: var(--ff-body); font-size: 14.5px; resize: vertical; transition: border-color .18s; }
.fld input:focus, .fld textarea:focus { outline: none; border-color: var(--accent); }
.fld-row { display: flex; gap: 14px; flex-wrap: wrap; }
.fld-check { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--muted); font-family: var(--ff-mono); }
.fld-check input { width: 17px; height: 17px; accent-color: var(--accent); }
.fld-hue { position: relative; }
.fld-hue input[type=range] { accent-color: var(--accent); }

/* image picker + gallery editor (admin) */
.imgpick { display: flex; flex-direction: column; gap: 9px; }
.imgpick-row { display: flex; align-items: center; gap: 14px; }
.imgpick-thumb { width: 92px; height: 70px; flex: none; border-radius: 8px; overflow: hidden; border: 1px solid var(--line-soft); background: var(--bg-2); display: grid; place-items: center; }
.imgpick-thumb img { width: 100%; height: 100%; object-fit: cover; }
.imgpick-thumb.empty span { color: var(--faint); font-size: 20px; }
.imgpick-controls { display: flex; gap: 8px; flex-wrap: wrap; }
.imgpick-btn { font-family: var(--ff-mono); font-size: 12px; padding: 8px 13px; border-radius: 8px; border: 1px solid var(--line); background: var(--bg-2); color: var(--text); transition: border-color .2s, color .2s; }
.imgpick-btn:hover:not(:disabled) { border-color: var(--accent); color: var(--accent-text); }
.imgpick-btn:disabled { opacity: 0.5; cursor: default; }
.imgpick-btn.danger:hover { border-color: oklch(0.65 0.2 25); color: oklch(0.75 0.2 25); }
.imgpick-url { font-family: var(--ff-mono); font-size: 12.5px; background: var(--bg); border: 1px solid var(--line-soft); border-radius: 8px; padding: 9px 11px; color: var(--text); }
.imgpick-url:focus { outline: none; border-color: var(--accent); }
.imgpick-hint { font-size: 11.5px; color: var(--faint); }

.galed { display: flex; flex-direction: column; gap: 12px; }
.galed-head { display: flex; align-items: center; gap: 14px; }
.galed-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; }
.galed-cell { position: relative; aspect-ratio: 1; border-radius: 8px; overflow: hidden; border: 1px solid var(--line-soft); background: var(--bg-2); }
.galed-cell img { width: 100%; height: 100%; object-fit: cover; }
.galed-cell-actions { position: absolute; inset: auto 0 0 0; display: flex; justify-content: center; gap: 4px; padding: 5px; background: linear-gradient(transparent, oklch(0.1 0.01 264 / 0.85)); opacity: 0; transition: opacity .15s; }
.galed-cell:hover .galed-cell-actions { opacity: 1; }
.galed-cell-actions button { width: 24px; height: 24px; border-radius: 6px; border: none; background: oklch(0.2 0.01 264 / 0.9); color: #fff; font-size: 12px; display: grid; place-items: center; }
.galed-cell-actions button:hover:not(:disabled) { background: var(--accent); color: var(--accent-ink); }
.galed-cell-actions button:disabled { opacity: 0.35; }
.galed-cell-actions button.danger:hover { background: oklch(0.6 0.22 25); color: #fff; }
.hue-swatch { height: 8px; border-radius: 4px; margin-top: 4px; }
.modal-foot .btn-solid:disabled { opacity: 0.4; cursor: not-allowed; }
@media (max-width: 560px) { .fld-row { flex-direction: column; gap: 16px; } }

/* repeatable edit cards (Toolkit groups, Roles & Activities entries) */
.edit-card { display: flex; flex-direction: column; gap: 12px; padding: 16px; border: 1px solid var(--line-soft); border-radius: 12px; background: var(--bg); }
.edit-card-head { display: flex; align-items: center; justify-content: space-between; }
.edit-card-n { font-family: var(--ff-mono); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--faint); }
.edit-card-actions { display: flex; gap: 6px; }
.edit-card-actions button { width: 30px; height: 30px; border-radius: 8px; border: 1px solid var(--line-soft); background: var(--bg-2); color: var(--text); font-size: 13px; display: grid; place-items: center; transition: border-color .2s, color .2s, opacity .2s; }
.edit-card-actions button:hover:not(:disabled) { border-color: var(--accent); color: var(--accent-text); }
.edit-card-actions button:disabled { opacity: 0.3; cursor: not-allowed; }
.edit-card-actions button.danger:hover:not(:disabled) { border-color: oklch(0.65 0.2 25); color: oklch(0.75 0.2 25); }
.add-row { font-family: var(--ff-mono); font-size: 13px; padding: 12px; border-radius: 10px; border: 1px dashed var(--line); background: transparent; color: var(--muted); transition: border-color .2s, color .2s; }
.add-row:hover { border-color: var(--accent); color: var(--accent-text); }
