:root {
  --post-dark: #122e61;
  --post-light: #26a1e5;
  --post-green: #66c766;
  --post-soft: #87c2e8;
  --bg: #f8fafc;
  --surface: #ffffff;
  --ink: #0f172a;
  --muted: #64748b;
  --border: #e2e8f0;
  --radius: 14px;
  --radius-lg: 22px;
  --shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 8px 24px -8px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 1px 2px rgba(15, 23, 42, 0.04), 0 24px 60px -24px rgba(15, 23, 42, 0.18);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: "Inter", system-ui, -apple-system, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}
h1, h2, h3, h4 {
  font-family: "Sora", sans-serif;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin: 0;
}

.brand strong {
  font-family: "Sora", sans-serif;
  font-size: 16px;
  letter-spacing: 0.02em;
  color: var(--post-dark);
}
.brand span {
  display: block;
  font-family: "Sora", sans-serif;
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 2px;
}

/* ─────────────────────  PIN-screen  ────────────────────── */
body.view-pin {
  background: linear-gradient(135deg, #0a1e44 0%, var(--post-dark) 50%, #1a4078 100%);
  display: grid;
  place-items: center;
  color: white;
}
body.view-pin::before {
  content: "";
  position: fixed;
  inset: 0;
  background: radial-gradient(ellipse 60% 50% at 50% 30%, var(--post-light) 0%, transparent 50%);
  opacity: 0.18;
  pointer-events: none;
  z-index: 0;
}
.pin-screen {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 420px;
  padding: 32px;
}
.pin-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(135, 194, 232, 0.18);
  backdrop-filter: blur(20px);
  border-radius: var(--radius-lg);
  padding: 40px 36px;
  text-align: center;
  box-shadow: 0 24px 60px -16px rgba(0, 0, 0, 0.4);
}
.pin-card .brand strong { color: white; }
.pin-card .brand span { color: rgba(255, 255, 255, 0.55); }
.pin-card h1 {
  font-size: 26px;
  color: white;
  margin: 28px 0 8px;
}
.pin-help {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.65);
  margin: 0 0 28px;
}
.pin-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.pin-form input {
  width: 100%;
  padding: 18px 20px;
  font-family: "Sora", sans-serif;
  font-size: 28px;
  font-weight: 700;
  letter-spacing: 0.3em;
  text-align: center;
  color: white;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 12px;
  outline: none;
  transition: border 0.15s, background 0.15s;
}
.pin-form input::placeholder { color: rgba(255, 255, 255, 0.25); }
.pin-form input:focus {
  border-color: var(--post-light);
  background: rgba(255, 255, 255, 0.1);
}
.pin-form button {
  padding: 14px 20px;
  font-family: "Sora", sans-serif;
  font-weight: 600;
  font-size: 14px;
  letter-spacing: 0.04em;
  color: var(--post-dark);
  background: white;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s;
}
.pin-form button:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 40px -10px rgba(255, 255, 255, 0.25);
}
.pin-error {
  margin-top: 18px;
  padding: 10px 14px;
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(239, 68, 68, 0.3);
  border-radius: 10px;
  color: #fecaca;
  font-size: 13px;
}

/* ─────────────────────  Topbar  ────────────────────── */
.topbar {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}
.topbar-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 18px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.logout {
  font-family: "Sora", sans-serif;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  text-decoration: none;
  padding: 8px 14px;
  border: 1px solid var(--border);
  border-radius: 999px;
  transition: color 0.15s, border-color 0.15s;
}
.logout:hover {
  color: var(--post-dark);
  border-color: var(--post-light);
}

/* ─────────────────────  Projects-screen  ────────────────────── */
.projects-screen {
  max-width: 1200px;
  margin: 0 auto;
  padding: 80px 32px 100px;
}
.hero {
  margin-bottom: 56px;
  max-width: 720px;
}
.hero .kicker {
  display: inline-block;
  font-family: "Sora", sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--post-light);
  margin-bottom: 16px;
}
.hero h1 {
  font-size: clamp(32px, 5vw, 48px);
  color: var(--post-dark);
  margin-bottom: 18px;
}
.hero p {
  color: var(--muted);
  font-size: 17px;
  margin: 0;
  line-height: 1.65;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 24px;
}
.project-card {
  --accent: var(--post-light);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  text-decoration: none;
  color: var(--ink);
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s;
  position: relative;
}
.project-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--accent);
  z-index: 1;
}
.project-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--accent);
}
.card-thumb {
  height: 140px;
  background: linear-gradient(135deg, var(--post-dark) 0%, #1a4078 100%);
  display: grid;
  place-items: center;
  position: relative;
  overflow: hidden;
}
.card-thumb::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 30% 100%, var(--accent) 0%, transparent 60%);
  opacity: 0.4;
}
.thumb-icon {
  font-family: "Sora", sans-serif;
  font-size: 56px;
  font-weight: 800;
  color: white;
  letter-spacing: -0.04em;
  position: relative;
  z-index: 1;
  text-shadow: 0 4px 24px rgba(0, 0, 0, 0.3);
}
.card-body {
  padding: 26px 28px 30px;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.card-body h3 {
  font-size: 19px;
  color: var(--post-dark);
  margin-bottom: 6px;
}
.card-tagline {
  font-size: 13px;
  color: var(--accent);
  font-weight: 600;
  margin: 0 0 12px;
}
.card-desc {
  font-size: 13.5px;
  color: var(--muted);
  margin: 0 0 16px;
  line-height: 1.6;
  flex: 1;
}
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 18px;
}
.tag {
  font-size: 11px;
  letter-spacing: 0.04em;
  padding: 3px 10px;
  background: var(--bg);
  border: 1px solid var(--border);
  color: var(--muted);
  border-radius: 999px;
}
.card-cta {
  font-family: "Sora", sans-serif;
  font-size: 13px;
  font-weight: 600;
  color: var(--accent);
}

/* ─────────────────────  Footer  ────────────────────── */
.page-foot {
  text-align: center;
  padding: 32px;
  font-size: 12px;
  color: var(--muted);
  border-top: 1px solid var(--border);
}

/* ─────────────────────  Mobile  ────────────────────── */
@media (max-width: 640px) {
  .topbar-inner { padding: 14px 20px; }
  .projects-screen { padding: 48px 20px 80px; }
  .hero { margin-bottom: 32px; }
  .pin-card { padding: 32px 24px; }
  .pin-card h1 { font-size: 22px; }
}
