/* ============================================================
   Jason C. Paugys — personal site
   Palette: warm coral, deep navy, soft gold, warm off-white
   ============================================================ */

:root {
  --coral: #1ac8db;
  --coral-dark: #0ea5b8;
  --navy: #1e3a8a;
  --navy-soft: #2a4ea8;
  --gold: #5cbfa8;
  --bg: #f4fbfc;
  --bg-tint: #e6f5f8;
  --card: #ffffff;
  --ink: #1c2b3a;
  --ink-soft: #5c6e7a;
  --line: #d0e8ee;

  --radius: 18px;
  --radius-sm: 10px;
  --shadow: 0 14px 34px rgba(30, 58, 138, 0.10);
  --shadow-sm: 0 6px 16px rgba(30, 58, 138, 0.08);
  --maxw: 1100px;

  --font-display: "Fraunces", Georgia, serif;
  --font-body: "Inter", system-ui, -apple-system, Segoe UI, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 84px; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

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

img { max-width: 100%; display: block; }
a { color: var(--coral-dark); }

h1, h2, h3 { font-family: var(--font-display); line-height: 1.15; color: var(--navy); }

.site-banner {
  display: block; width: 100%;
  background: var(--coral); color: #fff;
  text-align: center; padding: 18px 24px;
  font-size: 1.1rem; font-weight: 700; letter-spacing: 0.3px;
  box-sizing: border-box;
}

.skip-link {
  position: absolute; left: -999px; top: 0;
  background: var(--navy); color: #fff; padding: 10px 16px; z-index: 200;
  border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; }

/* ---------- Header / Nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255, 248, 240, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.nav {
  max-width: var(--maxw); margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 22px;
}
.brand-mark {
  font-family: var(--font-display); font-weight: 700; font-size: 1.25rem;
  background: var(--navy); color: var(--bg);
  padding: 8px 12px; border-radius: 10px; letter-spacing: 0.5px;
  display: inline-block;
}
.brand { text-decoration: none; }

.nav-menu {
  list-style: none; display: flex; gap: 6px; margin: 0; padding: 0;
  align-items: center;
}
.nav-menu a {
  text-decoration: none; color: var(--navy); font-weight: 500;
  padding: 8px 12px; border-radius: 8px; font-size: 0.95rem;
  transition: background 0.2s, color 0.2s;
}
.nav-menu a:hover { background: var(--bg-tint); }
.nav-menu a.is-current { color: var(--coral-dark); }
.nav-cta {
  background: var(--coral); color: #fff !important;
}
.nav-cta:hover { background: var(--coral-dark) !important; }

.nav-toggle {
  display: none; flex-direction: column; gap: 5px;
  background: none; border: 0; cursor: pointer; padding: 8px;
}
.nav-toggle span {
  width: 24px; height: 2.5px; background: var(--navy); border-radius: 2px;
  transition: transform 0.25s, opacity 0.2s;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; text-decoration: none; font-weight: 600;
  padding: 13px 24px; border-radius: 999px; font-size: 0.98rem;
  transition: transform 0.15s, box-shadow 0.2s, background 0.2s;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--coral); color: #fff; box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: var(--coral-dark); }
.btn-ghost { background: transparent; color: var(--navy); border: 2px solid var(--navy); }
.btn-ghost:hover { background: var(--navy); color: #fff; }

/* ---------- Hero ---------- */
.hero { padding: 56px 22px 72px; }
.hero-inner {
  max-width: var(--maxw); margin: 0 auto;
  display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 48px;
  align-items: center;
}
.hero-eyebrow {
  font-weight: 600; color: var(--coral-dark); margin: 0 0 10px;
  font-size: 1.05rem;
}
.hero-title { font-size: clamp(2.4rem, 5.5vw, 4rem); margin: 0 0 18px; font-weight: 700; }
.hero-title .accent { color: var(--coral); }
.hero-sub { font-size: 1.15rem; color: var(--ink-soft); margin: 0 0 22px; max-width: 32ch; }
.hero-tags {
  list-style: none; display: flex; gap: 10px; padding: 0; margin: 0 0 28px;
  flex-wrap: wrap;
}
.hero-tags li {
  background: var(--gold); color: var(--navy); font-weight: 600;
  padding: 6px 14px; border-radius: 999px; font-size: 0.9rem;
}
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }

.hero-photo { position: relative; display: flex; justify-content: center; }
.photo-frame {
  position: relative;
  width: clamp(200px, 27vw, 320px);
  aspect-ratio: 320 / 380;
  border-radius: 24px; overflow: hidden; z-index: 2;
  box-shadow: var(--shadow); border: 6px solid #fff;
}
.photo-frame img {
  width: 100%; height: 100%; object-fit: cover;
}
.photo-blob { display: none; }

/* ---------- Sections ---------- */
.section { padding: 72px 22px; }
.section-tint { background: var(--bg-tint); }
.section-contact { background: var(--navy); }
.section-inner { max-width: var(--maxw); margin: 0 auto; }

.kicker {
  text-transform: uppercase; letter-spacing: 2px; font-size: 0.78rem;
  font-weight: 600; color: var(--coral-dark); margin: 0 0 8px;
}
.section-title { font-size: clamp(1.9rem, 4vw, 2.8rem); margin: 0 0 14px; }
.section-intro { color: var(--ink-soft); max-width: 56ch; margin: 0 0 38px; font-size: 1.05rem; }
.lead { font-size: 1.2rem; color: var(--navy); font-weight: 500; }

/* ---------- About ---------- */
.about-grid { display: grid; grid-template-columns: 1.6fr 1fr; gap: 40px; align-items: start; }
.quick-facts {
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 26px; box-shadow: var(--shadow-sm);
}
.quick-facts h3 { margin: 0 0 14px; font-size: 1.25rem; }
.quick-facts ul { list-style: none; margin: 0; padding: 0; }
.quick-facts li {
  padding: 9px 0; border-bottom: 1px dashed var(--line);
  display: flex; gap: 10px; align-items: baseline;
}
.quick-facts li:last-child { border-bottom: 0; }
.quick-facts li span { font-size: 1.1rem; }

/* ---------- Story So Far ---------- */
.storylist {
  list-style: none; margin: 0; padding: 0;
  border-left: 3px solid var(--gold); padding-left: 30px;
  display: flex; flex-direction: column; gap: 30px;
}
.story {
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 26px 28px;
  box-shadow: var(--shadow-sm); position: relative;
}
.story::before {
  content: ""; position: absolute; left: -40px; top: 30px;
  width: 16px; height: 16px; background: var(--coral);
  border: 3px solid var(--bg-tint); border-radius: 50%;
}
.story-meta {
  display: flex; gap: 12px; align-items: center; flex-wrap: wrap;
  margin-bottom: 8px;
}
.story-where { font-weight: 600; color: var(--navy); }
.story-when {
  font-size: 0.82rem; color: var(--ink-soft);
  background: var(--bg-tint); padding: 3px 10px; border-radius: 999px;
}
.story-title { margin: 4px 0 10px; font-size: 1.4rem; }
.story-takeaway {
  margin: 12px 0 0; font-style: italic; color: var(--coral-dark);
  font-weight: 500;
}

.story.foundation {
  background: transparent; border: 1px dashed var(--line);
  box-shadow: none; opacity: 0.75;
}
.story.foundation::before { background: var(--gold); }
.story.foundation .story-title { font-size: 1.1rem; color: var(--ink-soft); }

/* ---------- Toolbox ---------- */
.toolbox-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px;
}
.tool-card {
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow-sm);
}
.tool-card h3 { margin: 0 0 14px; font-size: 1.25rem; }
.chips { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; }
.chips li {
  background: var(--bg-tint); color: var(--navy); font-weight: 500;
  padding: 6px 13px; border-radius: 999px; font-size: 0.88rem;
}
.chips.small li { font-size: 0.8rem; padding: 4px 10px; }

/* ---------- Projects ---------- */
.link-arrow {
  display: inline-block; margin-top: 12px; font-weight: 600;
  text-decoration: none; color: var(--coral-dark);
}
.link-arrow:hover { text-decoration: underline; }

/* Built subsections */
.built-subsection { margin-bottom: 52px; }
.built-subsection:last-child { margin-bottom: 0; }
.subsection-title {
  font-size: 1.5rem; margin: 0 0 22px;
  padding-bottom: 10px; border-bottom: 2px solid var(--gold);
  display: inline-block;
}

/* Website cards */
.websites-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px;
}
.website-card {
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow-sm);
  transition: transform 0.18s, box-shadow 0.2s;
  display: flex; flex-direction: column;
}
.website-card:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.website-body { padding: 24px; display: flex; flex-direction: column; flex: 1; }
.website-name {
  margin: 0 0 10px; font-size: 1.2rem; font-family: var(--font-display);
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
}
.website-name a { color: var(--navy); text-decoration: none; }
.website-name a:hover { color: var(--coral-dark); }
.website-badge {
  font-size: 0.72rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.8px;
  background: var(--bg-tint); color: var(--ink-soft); font-family: var(--font-body);
  padding: 3px 8px; border-radius: 999px;
}
.website-body p { color: var(--ink-soft); margin: 0; padding-bottom: 14px; flex: 1; }

/* Gen AI */
.genai-category { margin-bottom: 36px; }
.genai-category:last-child { margin-bottom: 0; }
.genai-category-title { font-size: 1.1rem; margin: 0 0 14px; }
.genai-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px;
}
.genai-grid.genai-empty {
  display: block; padding: 22px; text-align: center;
  background: transparent; border: 1px dashed var(--line); border-radius: var(--radius-sm);
}
.genai-empty-msg { margin: 0; color: var(--ink-soft); font-style: italic; }
.genai-item { display: flex; flex-direction: column; gap: 8px; }
.genai-thumb {
  aspect-ratio: 1; border-radius: var(--radius-sm); overflow: hidden;
  cursor: pointer; box-shadow: var(--shadow-sm);
  transition: transform 0.18s, box-shadow 0.2s;
}
.genai-thumb:hover { transform: scale(1.04); box-shadow: var(--shadow); }
.genai-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.genai-caption {
  margin: 0; font-size: 0.82rem; color: var(--ink-soft);
  line-height: 1.4; text-align: center;
}

/* Gen AI gallery CTA */
.genai-gallery-cta { margin-top: 28px; text-align: center; }

/* Lightbox */
.lightbox {
  position: fixed; inset: 0; z-index: 500;
  background: rgba(15, 23, 42, 0.92);
  display: flex; align-items: center; justify-content: center;
  padding: 24px;
  opacity: 0; pointer-events: none;
  transition: opacity 0.2s;
}
.lightbox.is-open { opacity: 1; pointer-events: all; }
.lightbox-img {
  max-width: 90vw; max-height: 85vh;
  border-radius: var(--radius-sm); box-shadow: 0 24px 60px rgba(0,0,0,0.5);
  display: block;
}
.lightbox-close {
  position: absolute; top: 20px; right: 24px;
  background: none; border: 0; color: #fff; font-size: 2rem;
  cursor: pointer; line-height: 1; padding: 4px 8px;
  opacity: 0.7; transition: opacity 0.15s;
}
.lightbox-close:hover { opacity: 1; }

/* ---------- Brain Dumps ---------- */
.dumps-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.dump-card {
  background: var(--card); border: 1px solid var(--line);
  border-left: 5px solid var(--gold);
  border-radius: var(--radius-sm); padding: 22px; box-shadow: var(--shadow-sm);
}
.dump-card.dump-empty {
  grid-column: 1 / -1; text-align: center;
  color: var(--ink-soft); font-style: italic; border-left: none;
  background: transparent; box-shadow: none;
  border: 1px dashed var(--line);
}
.dump-card time {
  font-size: 0.8rem; font-weight: 600; color: var(--coral-dark);
  text-transform: uppercase; letter-spacing: 1px;
}
.dump-card h3 { margin: 6px 0 8px; font-size: 1.2rem; }
.dump-card p { margin: 0; color: var(--ink-soft); }

/* ---------- Article pages ---------- */
.article-prose { max-width: 700px; margin: 0 auto; }
.article-prose p { margin: 0 0 22px; font-size: 1.05rem; color: var(--ink); }
.article-prose h2 { font-size: 1.4rem; margin: 40px 0 14px; }
.article-prose h2:first-child { margin-top: 0; }
.article-prose ul { margin: 0 0 22px; padding-left: 1.4em; }
.article-prose li { margin-bottom: 8px; font-size: 1.05rem; color: var(--ink); line-height: 1.65; }
.article-prose li:last-child { margin-bottom: 0; }
.sim-embed-wrap { max-width: 1200px; margin: 0 auto; }
.privacy-note {
  background: var(--bg-tint); border: 1px dashed var(--line);
  border-radius: var(--radius-sm); padding: 14px 18px;
  font-size: 0.92rem; color: var(--ink-soft); margin: 0 0 8px;
}

/* ---------- Contact ---------- */
.section-contact .kicker { color: var(--gold); }
.section-contact .section-title { color: #fff; }
.section-contact .section-intro { color: #a8c8e8; }
.contact-inner { text-align: center; }
.contact-inner .section-intro { margin-left: auto; margin-right: auto; }
.contact-links { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.section-contact .btn-ghost { color: #fff; border-color: #fff; }
.section-contact .btn-ghost:hover { background: #fff; color: var(--navy); }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--navy); color: #c8d0e0;
  padding: 22px; text-align: center;
  display: flex; justify-content: center; gap: 18px; flex-wrap: wrap;
  border-top: 1px solid var(--navy-soft);
}
.site-footer p { margin: 0; }
.back-to-top { color: var(--gold); text-decoration: none; font-weight: 600; }

/* ---------- Reveal animation ---------- */
.section, .hero-inner { }
[data-reveal] {
  opacity: 0; transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
[data-reveal].is-visible { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .hero { padding: 36px 22px 48px; }
  .hero-inner { gap: 28px; }
  .section { padding: 52px 22px; }
}

@media (max-width: 860px) {
  .nav-toggle { display: flex; }
  .nav-menu {
    position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 2px;
    background: var(--bg); border-bottom: 1px solid var(--line);
    padding: 12px 18px; display: none;
  }
  .nav-menu.is-open { display: flex; }
  .nav-menu a { padding: 12px; }
  .nav-cta { text-align: center; }

  .hero-inner { grid-template-columns: 1fr; gap: 36px; }
  .hero-photo { order: -1; }
  .photo-frame { width: min(260px, 65vw); }
  .about-grid { grid-template-columns: 1fr; }
  .toolbox-grid { grid-template-columns: 1fr; }
  .dumps-grid { grid-template-columns: 1fr; }
  .websites-grid { grid-template-columns: 1fr; }
}
