/* ==========================================================================
   Skoolyn — Premium discovery dashboard design system
   Pinterest-inspired visual language (original design, no copied assets):
   white canvas, narrow icon sidebar, wide rounded search, true masonry
   feed, one consistent line-icon family, neutral palette, generous space.
   ========================================================================== */

:root {
  --bg: #ffffff;
  --bg-soft: #f7f7f5;
  --input-bg: #edede9;
  --ink: #111111;
  --text: #666666;
  --muted: #999999;
  --line: #e6e6e3;

  --brand: #0d6b5d;
  --brand-2: #1d8d78;
  --brand-soft: #e4f4ef;
  --red: #e60023;
  --red-soft: #fdeef0;

  --radius: 16px;
  --radius-sm: 12px;
  --radius-search: 27px;

  --shadow-xs: 0 1px 2px rgba(0,0,0,.03), 0 2px 10px rgba(0,0,0,.04);
  --shadow-sm: 0 2px 6px rgba(0,0,0,.05), 0 4px 16px rgba(0,0,0,.05);
  --shadow-md: 0 6px 14px rgba(0,0,0,.06), 0 14px 34px rgba(0,0,0,.08);

  --ease: cubic-bezier(.25,.1,.25,1);
}

/* ---------- Canvas ---------- */
body.app-body { background: var(--bg); color: var(--ink); }
.app-shell { display: flex; min-height: 100vh; background: var(--bg); }

/* ==========================================================================
   Sidebar — vertical rail with icon + label
   ========================================================================== */
.pin-sidebar {
  width: 236px;
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 40;
  background: var(--bg);
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  padding: 18px 14px 16px;
}
.pin-sidebar-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 18px;
  padding: 0 6px;
}
.pin-sidebar-top .sidebar-close { display: none; }

.pin-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  transition: opacity .2s var(--ease);
}
.pin-logo:hover { opacity: .82; }
.pin-logo-mark {
  width: 40px; height: 40px;
  border-radius: 12px;
  display: grid; place-items: center;
  flex: none;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  color: #fff;
  box-shadow: 0 4px 12px rgba(13,107,93,.22);
  transition: transform .2s var(--ease), box-shadow .2s var(--ease);
}
.pin-logo:hover .pin-logo-mark { transform: translateY(-1px); box-shadow: 0 6px 16px rgba(13,107,93,.30); }
.pin-logo-text { display: flex; flex-direction: column; line-height: 1.05; }
.pin-logo-text strong { font-size: 16px; letter-spacing: -.03em; }
.pin-logo-text small { font-size: 9px; font-weight: 800; letter-spacing: .18em; color: var(--brand); margin-top: 3px; text-transform: uppercase; }

.pin-nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
  width: 100%;
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
}
.pin-nav-link {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 10px 12px;
  border-radius: 12px;
  color: #555;
  font-size: 13.5px;
  font-weight: 600;
  letter-spacing: -.01em;
  white-space: nowrap;
  transition: background .18s var(--ease), color .18s var(--ease), transform .18s var(--ease);
}
.pin-nav-link .icon { flex: none; transition: transform .18s var(--ease); }
.pin-nav-label { overflow: hidden; text-overflow: ellipsis; }
.pin-nav-link:hover { background: var(--bg-soft); color: var(--ink); }
.pin-nav-link:hover .icon { transform: scale(1.06); }
.pin-nav-link.active { background: var(--ink); color: #fff; }
.pin-nav-link.active:hover { background: #000; }

.pin-sidebar-foot {
  margin-top: 12px;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

/* ==========================================================================
   Header — wide rounded search bar + actions
   ========================================================================== */
.pin-main { width: calc(100% - 236px); margin-left: 236px; min-width: 0; }
.pin-topbar {
  position: sticky; top: 0; z-index: 30;
  display: flex; align-items: center; gap: 16px;
  height: 88px;
  padding: 0 32px;
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}
.pin-topbar .mobile-menu { display: none; }

.pin-search {
  flex: 1;
  max-width: 780px;
  margin: 0 auto;
  display: flex; align-items: center; gap: 12px;
  height: 54px;
  padding: 0 8px 0 20px;
  background: var(--input-bg);
  border: 2px solid transparent;
  border-radius: var(--radius-search);
  transition: background .2s var(--ease), border-color .2s var(--ease), box-shadow .2s var(--ease);
}
.pin-search:hover { background: #e6e6e1; }
.pin-search:focus-within {
  background: #fff;
  border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(13,107,93,.10);
}
.pin-search > .icon { color: #777; flex: none; }
.pin-search input {
  flex: 1; min-width: 0;
  border: 0; outline: 0; background: transparent;
  font-size: 14.5px; font-weight: 500; color: var(--ink);
}
.pin-search input::placeholder { color: #9a9a96; }
.pin-search-actions { display: flex; align-items: center; gap: 2px; flex: none; }
.pin-search-action {
  width: 38px; height: 38px;
  border: 0; background: transparent;
  border-radius: 50%;
  display: grid; place-items: center;
  color: #777;
  transition: background .15s var(--ease), color .15s var(--ease);
}
.pin-search-action:hover { background: rgba(0,0,0,.06); color: var(--ink); }

.pin-topbar-actions {
  margin-left: auto; flex: none;
  display: flex; align-items: center; gap: 12px;
}
.pin-icon-btn {
  position: relative;
  width: 44px; height: 44px;
  border-radius: 12px;
  display: grid; place-items: center;
  color: #555;
  transition: background .18s var(--ease), color .18s var(--ease), transform .18s var(--ease);
}
.pin-icon-btn:hover { background: var(--bg-soft); color: var(--ink); transform: scale(1.04); }
.pin-notif-dot {
  position: absolute; top: 9px; right: 9px;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--red);
  border: 2px solid #fff;
}

/* Account menu */
.pin-profile { position: relative; }
.pin-profile-btn {
  display: flex; align-items: center; gap: 7px;
  border: 0; background: transparent;
  padding: 4px 6px 4px 4px;
  border-radius: 999px;
  transition: background .18s var(--ease);
}
.pin-profile-btn:hover { background: var(--bg-soft); }
.pin-profile-btn .avatar {
  width: 40px; height: 40px;
  border: 2px solid #fff;
  box-shadow: 0 0 0 1px var(--line);
}
.pin-profile-btn > .icon { color: var(--muted); }
.pin-profile-menu {
  position: absolute; right: 0; top: calc(100% + 10px);
  min-width: 196px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--shadow-md);
  padding: 6px;
  opacity: 0;
  transform: translateY(6px) scale(.98);
  pointer-events: none;
  transition: opacity .18s var(--ease), transform .18s var(--ease);
  z-index: 70;
}
.pin-profile-menu.open { opacity: 1; transform: none; pointer-events: auto; }
.pin-profile-menu a {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 12px;
  border-radius: 9px;
  font-size: 13.5px; font-weight: 500;
  color: var(--ink);
  transition: background .15s var(--ease);
}
.pin-profile-menu a:hover { background: var(--bg-soft); }
.pin-profile-menu a .icon { color: var(--text); }

/* ==========================================================================
   Page content
   ========================================================================== */
.pin-main .page-content {
  max-width: 1620px;
  margin: 0 auto;
  padding: 30px 34px 100px;
  animation: pin-fade .35s var(--ease);
}
@keyframes pin-fade { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* ---------- Page headings ---------- */
.page-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 26px; }
.page-heading h1 { font-size: 30px; font-weight: 650; letter-spacing: -.035em; margin: 6px 0 6px; color: var(--ink); }
.page-heading p { margin: 0; font-size: 14px; color: var(--text); }
.page-heading .eyebrow { font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); display: inline-block; }
.page-heading-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }

.section-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 14px; margin: 34px 0 16px; }
.section-heading h2 { font-size: 17px; font-weight: 650; letter-spacing: -.02em; margin: 0; color: var(--ink); }
.section-heading p { color: var(--muted); font-size: 12.5px; margin: 4px 0 0; }

/* ---------- Buttons ---------- */
.button {
  border: 0; border-radius: var(--radius-sm);
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 18px;
  font-size: 14px; font-weight: 600;
  transition: background .18s var(--ease), box-shadow .18s var(--ease), transform .18s var(--ease), border-color .18s var(--ease);
}
.button-primary { background: var(--brand); color: #fff; box-shadow: 0 2px 8px rgba(13,107,93,.18); }
.button-primary:hover { background: var(--brand-2); box-shadow: 0 4px 14px rgba(13,107,93,.25); transform: translateY(-1px); }
.button-soft { background: var(--brand-soft); color: var(--brand); }
.button-soft:hover { background: #d9ece4; }
.button-white { background: #fff; border: 1px solid var(--line); color: var(--ink); }
.button-white:hover { background: var(--bg-soft); border-color: #d8d8d4; }
.button-danger { background: var(--red); color: #fff; }
.button-danger:hover { background: #c0001e; }
.button-sm { padding: 8px 14px; font-size: 13px; border-radius: 10px; }
.button-block { width: 100%; }
.icon-button {
  border: 0; background: transparent; color: var(--text);
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 10px; padding: 8px;
  transition: background .15s var(--ease), color .15s var(--ease);
}
.icon-button:hover { background: var(--bg-soft); color: var(--ink); }

.text-link { color: var(--brand); font-weight: 600; font-size: 13px; display: inline-flex; align-items: center; gap: 4px; transition: color .15s var(--ease); }
.text-link:hover { color: var(--brand-2); }

/* ---------- Tags ---------- */
.tag { display: inline-flex; align-items: center; gap: 5px; padding: 4px 10px; border-radius: 999px; font-size: 11px; font-weight: 600; }
.tag-soft { background: var(--bg-soft); color: var(--text); }
.tag-green { background: var(--brand-soft); color: var(--brand); }
.tag-orange { background: #fdf1e7; color: #b5632a; }
.tag-purple { background: #f3effb; color: #6d4fc4; }
.tag-red { background: var(--red-soft); color: #c0142f; }

/* ==========================================================================
   Masonry feed
   ========================================================================== */
.pin-masonry { columns: 5 220px; column-gap: 18px; }
.pin-card {
  break-inside: avoid;
  margin-bottom: 18px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-xs);
  overflow: hidden;
  transition: transform .2s var(--ease), box-shadow .2s var(--ease);
}
.pin-card:hover { transform: translateY(-2px) scale(1.01); box-shadow: var(--shadow-md); }
.pin-card--pad { padding: 20px; }

/* Media cards */
.pin-card-media { position: relative; display: block; overflow: hidden; background: var(--bg-soft); }
.pin-card-media img,
.pin-card-media .course-gradient { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.pin-card-media img { transition: transform .45s var(--ease); }
.pin-card:hover .pin-card-media img { transform: scale(1.03); }
.pin-card-media--wide { aspect-ratio: 16 / 10; }
.pin-card-media--med { aspect-ratio: 1 / 1; }
.pin-card-media--tall { aspect-ratio: 3 / 4; }

.pin-price {
  position: absolute; left: 10px; top: 10px; z-index: 2;
  background: rgba(255,255,255,.92);
  color: var(--ink);
  font-size: 11px; font-weight: 600;
  padding: 4px 10px;
  border-radius: 999px;
  box-shadow: var(--shadow-xs);
}
.pin-overlay {
  position: absolute; inset: 0; z-index: 2;
  display: flex; align-items: flex-end; justify-content: flex-end;
  padding: 12px;
  background: linear-gradient(to top, rgba(17,17,17,.35), transparent 60%);
  opacity: 0;
  transition: opacity .2s var(--ease);
}
.pin-card:hover .pin-overlay { opacity: 1; }
.pin-btn {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--brand);
  color: #fff;
  font-size: 12.5px; font-weight: 600;
  padding: 9px 16px;
  border-radius: 999px;
  box-shadow: 0 4px 14px rgba(0,0,0,.18);
  transition: background .18s var(--ease), transform .18s var(--ease);
}
.pin-btn:hover { background: var(--brand-2); transform: scale(1.04); }
.pin-btn.pin-btn-green { background: var(--brand); }
.pin-btn.pin-btn-green:hover { background: var(--brand-2); }
.pin-btn--block { width: 100%; justify-content: center; }

.pin-card-body { padding: 14px 16px 16px; }
.pin-card-title { margin: 0; font-size: 14.5px; font-weight: 650; letter-spacing: -.015em; line-height: 1.35; color: var(--ink); }
.pin-card-title a { color: inherit; transition: color .15s var(--ease); }
.pin-card-title a:hover { color: var(--brand); }
.pin-card-meta {
  display: flex; align-items: center; gap: 6px; flex-wrap: wrap;
  margin-top: 7px;
  color: var(--muted); font-size: 11.5px;
}
.pin-card-meta .avatar { width: 20px; height: 20px; font-size: 8px; }

.pin-progress { margin-top: 12px; }
.progress-line { height: 6px; border-radius: 999px; background: var(--input-bg); overflow: hidden; }
.progress-line > span { display: block; height: 100%; border-radius: 999px; background: var(--brand); }
.pin-progress small { color: var(--muted); font-size: 10.5px; margin-top: 5px; display: block; }

/* ---------- Card head ---------- */
.pin-card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; margin-bottom: 16px; }
.pin-card-head h3 { margin: 0; font-size: 14px; font-weight: 650; letter-spacing: -.01em; color: var(--ink); }
.pin-card-head p { margin: 3px 0 0; font-size: 11.5px; color: var(--muted); }
.pin-card-head > .icon { color: var(--muted); }

/* ---------- Stat card ---------- */
.pin-stat { display: flex; flex-direction: column; gap: 20px; }
.pin-stat-top { display: flex; align-items: center; justify-content: space-between; }
.pin-stat-icon { width: 42px; height: 42px; border-radius: 13px; background: var(--bg-soft); color: var(--ink); display: grid; place-items: center; }
.pin-stat-icon.brand { background: var(--brand-soft); color: var(--brand); }
.pin-stat-bottom { display: flex; flex-direction: column; gap: 4px; }
.pin-stat-value { font-size: 28px; font-weight: 650; letter-spacing: -.03em; line-height: 1; color: var(--ink); }
.pin-stat-label { font-size: 12.5px; color: var(--text); }
.pin-stat-delta { font-size: 11px; color: var(--muted); font-weight: 500; }

/* ---------- List card ---------- */
.pin-list { display: flex; flex-direction: column; }
.pin-list-item {
  display: flex; align-items: center; gap: 12px;
  padding: 9px 6px;
  border-radius: 11px;
  transition: background .15s var(--ease);
}
.pin-list-item:hover { background: var(--bg-soft); }
.pin-list-icon { width: 36px; height: 36px; border-radius: 11px; background: var(--bg-soft); color: var(--ink); display: grid; place-items: center; flex: none; }
.pin-list-icon.brand { background: var(--brand-soft); color: var(--brand); }
.pin-list-copy { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.pin-list-copy strong { font-size: 13px; font-weight: 600; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pin-list-copy span { font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pin-list-time { font-size: 10.5px; color: var(--muted); flex: none; }
.pin-list a.pin-list-item { color: inherit; }

/* Activity dot */
.activity-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--input-bg); flex: none; }
.activity-dot.green { background: var(--brand); }
.activity-dot.orange { background: #e8a25e; }
.activity-dot.purple { background: #8b6fd8; }

/* ---------- Mini bar chart (analytics card) ---------- */
.pin-bars { display: flex; align-items: flex-end; gap: 8px; height: 96px; margin-top: 18px; }
.pin-bars span {
  flex: 1; min-width: 0;
  border-radius: 7px 7px 4px 4px;
  background: var(--input-bg);
  transition: background .2s var(--ease), transform .2s var(--ease);
  position: relative;
}
.pin-bars span:hover { background: #dcdcd6; }
.pin-bars span.brand { background: var(--brand); }
.pin-bars small {
  position: absolute; left: 50%; bottom: -20px;
  transform: translateX(-50%);
  font-size: 9px; color: var(--muted);
  white-space: nowrap; max-width: 60px; overflow: hidden; text-overflow: ellipsis;
}
.pin-legend { display: flex; align-items: center; gap: 7px; font-size: 11px; color: var(--muted); margin-top: 26px; }
.pin-legend i { width: 8px; height: 8px; border-radius: 3px; background: var(--brand); display: inline-block; }

/* ---------- Shared cards (non-masonry pages) ---------- */
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-xs); }
.card-pad { padding: 22px; }
.card-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; margin-bottom: 18px; }
.card-header h2, .card-header h3 { margin: 0; font-size: 15px; font-weight: 650; letter-spacing: -.01em; color: var(--ink); }
.card-header p { margin: 4px 0 0; color: var(--muted); font-size: 12px; }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; }
.data-table thead th {
  font-size: 10.5px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase;
  color: var(--muted); text-align: left;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
.data-table tbody td { padding: 13px 14px; border-bottom: 1px solid #f2f2ef; font-size: 13px; color: var(--text); }
.data-table tbody tr:last-child td { border-bottom: 0; }
.data-table tbody tr:hover td { background: #fafaf8; }
.data-table code { background: var(--bg-soft); padding: 2px 7px; border-radius: 7px; font-size: 11.5px; color: var(--text); }
.table-actions { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.mini-button {
  border: 1px solid var(--line); background: #fff;
  border-radius: 9px; padding: 6px 10px;
  font-size: 11px; font-weight: 600; color: var(--text);
  transition: background .15s var(--ease), border-color .15s var(--ease), color .15s var(--ease);
}
.mini-button:hover { background: var(--bg-soft); border-color: #dcdcd8; color: var(--ink); }
.mini-button.danger { color: var(--red); border-color: #f3c9cf; background: var(--red-soft); }
.mini-button.danger:hover { background: #fbd9de; }

/* ---------- Forms ---------- */
.field { margin-bottom: 16px; }
.field label { display: block; font-size: 12.5px; font-weight: 600; color: var(--ink); margin-bottom: 7px; }
.field input, .field select, .field textarea,
input[type="text"], input[type="email"], input[type="password"], input[type="number"], input[type="date"], input[type="search"],
select, textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  font-size: 14px;
  color: var(--ink);
  background: #fff;
  transition: border-color .18s var(--ease), box-shadow .18s var(--ease);
}
.field input:focus, .field select:focus, .field textarea:focus,
input:focus, select:focus, textarea:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(13,107,93,.10);
  outline: none;
}
.field input::placeholder, input::placeholder, textarea::placeholder { color: #b0b0ab; }
.form-note { font-size: 12.5px; color: var(--muted); }

/* ---------- Empty states ---------- */
.empty-state {
  border: 1.5px dashed #dcdcd8;
  border-radius: var(--radius);
  background: #fff;
  padding: 38px 24px;
  text-align: center;
  color: var(--muted);
}
.empty-state .empty-icon {
  width: 48px; height: 48px;
  border-radius: 15px;
  background: var(--bg-soft);
  color: var(--text);
  display: grid; place-items: center;
  margin: 0 auto 14px;
}
.empty-state h3 { margin: 0 0 5px; color: var(--ink); font-size: 15px; font-weight: 650; }
.empty-state p { margin: 0 auto 16px; max-width: 400px; font-size: 13px; }

/* ---------- Toast ---------- */
.toast {
  position: fixed; right: 24px; top: 24px; z-index: 1000;
  max-width: 360px;
  padding: 13px 14px 13px 16px;
  border-radius: 14px;
  background: #fff;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-md);
  font-size: 13px; font-weight: 600;
  display: flex; align-items: center; gap: 10px;
  animation: pin-fade .25s var(--ease);
}
.toast button { margin-left: auto; color: inherit; border: 0; background: transparent; padding: 2px; }
.toast-success { color: var(--brand); border-left: 3px solid var(--brand); }
.toast-error { color: var(--red); border-left: 3px solid var(--red); }
.toast-warning { color: #9a6a1f; border-left: 3px solid #e8b04b; }
.toast-info { color: var(--brand); border-left: 3px solid var(--brand); }

/* ---------- Inline alerts ---------- */
.inline-alert { border-radius: 12px; padding: 12px 14px; font-size: 13px; font-weight: 500; border: 1px solid var(--line); background: var(--bg-soft); color: var(--text); }
.alert-success { background: var(--brand-soft); border-color: #c9e4da; color: var(--brand); }
.alert-error { background: var(--red-soft); border-color: #f3c9cf; color: #c0142f; }
.alert-warning { background: #fdf4e8; border-color: #f0dcbc; color: #8a5d1c; }
.alert-info { background: #eef3fb; border-color: #d5e0f2; color: #34548c; }

/* ==========================================================================
   Mobile bottom navigation
   ========================================================================== */
.mobile-nav { display: none; }

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (min-width: 1600px) {
  .pin-masonry { columns: 6 215px; }
}

@media (max-width: 1200px) {
  .pin-masonry { columns: 4 200px; }
  .pin-main .page-content { padding: 26px 24px 96px; }
  .pin-topbar { padding: 0 24px; }
}

@media (max-width: 850px) {
  .pin-sidebar {
    width: min(300px, 84vw);
    transform: translateX(-102%);
    transition: transform .25s var(--ease);
    box-shadow: 0 0 40px rgba(17,17,17,.16);
    padding: 20px 16px;
  }
  .pin-sidebar.open { transform: none; }
  .pin-sidebar-top { padding: 0; margin-bottom: 22px; }
  .pin-sidebar-top .sidebar-close { display: inline-flex; }
  .pin-nav { align-items: stretch; }
  .pin-nav-link { border-radius: 13px; }
  .pin-sidebar-foot { align-items: stretch; }
  .sidebar-overlay {
    position: fixed; inset: 0; z-index: 35;
    background: rgba(17,17,17,.28);
    display: none;
  }
  .sidebar-overlay.open { display: block; }

  .pin-main { width: 100%; margin-left: 0; }
  .pin-topbar { height: 76px; padding: 0 14px; gap: 10px; }
  .pin-topbar .mobile-menu { display: inline-flex; }
  .pin-search { height: 46px; border-radius: 23px; max-width: none; padding-left: 16px; }
  .pin-search input { font-size: 14px; }
  .pin-main .page-content { padding: 22px 16px 100px; }
  .pin-masonry { columns: 2 170px; column-gap: 12px; }
  .pin-card { margin-bottom: 12px; }
  .page-heading h1 { font-size: 26px; }

  .mobile-nav {
    display: flex;
    position: fixed; bottom: 0; left: 0; right: 0; z-index: 45;
    height: 68px;
    background: rgba(255,255,255,.96);
    backdrop-filter: blur(14px);
    border-top: 1px solid var(--line);
    justify-content: space-around;
    align-items: center;
    padding: 0 6px calc(6px + env(safe-area-inset-bottom));
  }
  .mobile-nav-link {
    display: flex; flex-direction: column; align-items: center; gap: 3px;
    font-size: 9.5px; font-weight: 600;
    color: var(--muted);
    padding: 6px 12px;
    border-radius: 12px;
    transition: color .15s var(--ease), background .15s var(--ease);
  }
  .mobile-nav-link:hover, .mobile-nav-link.active { color: var(--ink); }
  .mobile-nav-link.active { color: var(--brand); }
}

@media (max-width: 560px) {
  .pin-topbar { padding: 0 10px; height: 70px; }
  .pin-topbar-actions { gap: 6px; }
  .pin-profile-btn > .icon { display: none; }
  .pin-search-action { width: 34px; height: 34px; }
  .pin-main .page-content { padding: 16px 12px 100px; }
  .pin-masonry { columns: 1; }
  .pin-card { border-radius: 14px; }
  .page-heading { display: block; margin-bottom: 20px; }
  .page-heading-actions { margin-top: 14px; }
  .page-heading h1 { font-size: 24px; }
  .section-heading { margin-top: 28px; }
  .card-pad { padding: 16px; }
  .pin-card--pad { padding: 16px; }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *:before, *:after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}
