:root {
  --chrome-bg: #eeece7;
  --chrome-panel: rgba(255, 255, 255, 0.8);
  --chrome-panel-strong: rgba(255, 255, 255, 0.92);
  --chrome-line: rgba(17, 17, 17, 0.12);
  --chrome-ink: #111111;
  --chrome-muted: #5f5f5f;
  --chrome-shadow: 0 18px 50px rgba(17, 17, 17, 0.08);
  --resume-ink: #111111;
  --resume-line: #111111;
  --resume-soft-line: #c7c7c7;
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  font-size: 16px;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--chrome-ink);
  font-family: "Avenir Next", "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.95), transparent 24%),
    linear-gradient(180deg, #f3f1ed 0%, #ebe7df 100%);
}

.site-home {
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.96), transparent 22%),
    linear-gradient(135deg, #efe5d8 0%, #ece6dc 42%, #d9d5d1 100%);
}

button,
textarea {
  font: inherit;
}

a {
  color: inherit;
}

.site-shell {
  width: min(1240px, calc(100% - 32px));
  margin: 28px auto 40px;
}

.home-hero {
  padding: 36px;
  border: 1px solid rgba(17, 17, 17, 0.08);
  border-radius: 32px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.94), rgba(255, 251, 246, 0.82)),
    radial-gradient(circle at top right, rgba(200, 173, 127, 0.18), transparent 32%);
  box-shadow: 0 18px 48px rgba(17, 17, 17, 0.08);
}

.home-kicker,
.product-label {
  margin: 0 0 10px;
  color: #8b5e34;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.home-hero h1 {
  margin: 0;
  font-family: "Iowan Old Style", "Palatino Linotype", serif;
  font-size: clamp(2.8rem, 5vw, 5rem);
  line-height: 0.95;
}

.home-lede {
  max-width: 60ch;
  margin: 14px 0 0;
  color: #5f5f5f;
  line-height: 1.6;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 18px;
  margin-top: 22px;
}

.product-card {
  display: flex;
  flex-direction: column;
  min-height: 320px;
  padding: 24px;
  border: 1px solid rgba(17, 17, 17, 0.08);
  border-radius: 28px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(250, 246, 239, 0.86));
  box-shadow: 0 16px 42px rgba(17, 17, 17, 0.08);
}

.product-card--active {
  position: relative;
  overflow: hidden;
}

.product-card--active::after {
  content: "";
  position: absolute;
  inset: auto -40px -40px auto;
  width: 180px;
  height: 180px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(210, 181, 132, 0.28), transparent 68%);
  pointer-events: none;
}

.product-card-head h2 {
  margin: 0;
  font-family: "Iowan Old Style", "Palatino Linotype", serif;
  font-size: 1.9rem;
}

.product-copy {
  margin: 14px 0 0;
  color: #5f5f5f;
  line-height: 1.6;
}

.product-meta {
  margin: 18px 0 0;
  padding-left: 18px;
  color: #2a2a2a;
}

.product-meta li + li {
  margin-top: 6px;
}

.product-link,
.product-placeholder,
.home-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid rgba(17, 17, 17, 0.16);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  text-decoration: none;
}

.product-link {
  margin-top: auto;
  width: fit-content;
  background: #111111;
  color: #ffffff;
  border-color: #111111;
}

.product-placeholder {
  margin-top: auto;
  width: fit-content;
  color: #5f5f5f;
}

.product-snapshot {
  margin: 18px 0 0;
}

.snapshot-window {
  padding: 14px;
  border: 1px solid rgba(17, 17, 17, 0.1);
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(243, 236, 227, 0.82));
}

.snapshot-dots {
  display: flex;
  gap: 6px;
}

.snapshot-dots span {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: rgba(17, 17, 17, 0.18);
}

.snapshot-lines {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.snapshot-line {
  height: 12px;
  border-radius: 999px;
  background: rgba(17, 17, 17, 0.1);
}

.snapshot-line--long {
  width: 84%;
}

.snapshot-line--medium {
  width: 58%;
}

.snapshot-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.snapshot-grid span {
  height: 72px;
  border-radius: 18px;
  background: rgba(210, 181, 132, 0.28);
  border: 1px solid rgba(17, 17, 17, 0.08);
}

.article-preview-list {
  margin: 16px 0 0;
  padding-left: 18px;
  color: #2a2a2a;
}

.article-preview-list li + li {
  margin-top: 8px;
}

.app-shell {
  width: min(1440px, calc(100% - 32px));
  margin: 24px auto;
}

.topbar {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: flex-start;
  padding: 28px 32px;
  border: 1px solid var(--chrome-line);
  border-radius: var(--radius);
  background: var(--chrome-panel-strong);
  box-shadow: var(--chrome-shadow);
}

.eyebrow,
.panel-kicker {
  margin: 0 0 8px;
  color: var(--chrome-muted);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.topbar h1,
.panel-head h2 {
  margin: 0;
  font-family: "Iowan Old Style", "Palatino Linotype", serif;
  font-weight: 700;
}

.topbar h1 {
  font-size: clamp(2rem, 3vw, 3.2rem);
  line-height: 1;
}

.lede,
.panel-note,
.feedback-ok,
.parse-feedback li {
  color: var(--chrome-muted);
}

.lede {
  max-width: 60ch;
  margin: 10px 0 0;
  line-height: 1.55;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

button {
  border: 1px solid rgba(17, 17, 17, 0.18);
  border-radius: 999px;
  padding: 12px 18px;
  cursor: pointer;
  transition: transform 150ms ease, background 150ms ease, border-color 150ms ease;
  background: rgba(255, 255, 255, 0.82);
  color: var(--chrome-ink);
}

.font-control {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border: 1px solid rgba(17, 17, 17, 0.18);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--chrome-ink);
}

.font-control span {
  font-size: 0.92rem;
}

.font-control select {
  border: 0;
  background: transparent;
  color: inherit;
}

.font-control select:focus {
  outline: none;
}

button:hover {
  transform: translateY(-1px);
}

button.primary {
  border-color: #111111;
  background: #111111;
  color: #ffffff;
}

button.secondary {
  background: transparent;
}

.workspace {
  display: grid;
  grid-template-columns: minmax(320px, 0.92fr) minmax(360px, 1.28fr);
  gap: 20px;
  margin-top: 20px;
}

.panel {
  min-width: 0;
  padding: 24px;
  border-radius: var(--radius);
  border: 1px solid var(--chrome-line);
  background: var(--chrome-panel);
  box-shadow: var(--chrome-shadow);
}

.panel-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.panel-head h2 {
  font-size: 1.45rem;
}

.panel-kicker,
.panel-note {
  margin-bottom: 4px;
}

.editor-panel textarea {
  width: 100%;
  min-height: 720px;
  padding: 22px;
  border: 1px solid rgba(17, 17, 17, 0.18);
  border-radius: 20px;
  resize: vertical;
  color: var(--chrome-ink);
  background: #ffffff;
  font-family: "SF Mono", "Roboto Mono", monospace;
  line-height: 1.7;
}

.syntax-guide {
  margin-top: 18px;
  border: 1px solid var(--chrome-line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.84);
}

.syntax-guide summary {
  cursor: pointer;
  padding: 16px 18px;
  font-weight: 600;
}

.syntax-guide pre {
  margin: 0;
  padding: 0 18px 18px;
  overflow-x: auto;
  font-family: "SF Mono", "Roboto Mono", monospace;
  font-size: 0.9rem;
  line-height: 1.7;
}

.parse-feedback {
  margin-bottom: 16px;
  padding: 14px 16px;
  border: 1px solid rgba(17, 17, 17, 0.14);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.9);
}

.parse-feedback ul {
  margin: 0;
  padding-left: 18px;
}

.parse-feedback p {
  margin: 0;
}

.resume-stage {
  overflow: auto;
  padding: 18px;
  border-radius: 20px;
  background: #d8d6d1;
}

.resume-paper {
  width: min(100%, 8.5in);
  min-height: 11in;
  margin: 0 auto;
  padding: 0.45in 0.55in 0.55in;
  border: 0;
  background: #ffffff;
  color: var(--resume-ink);
  box-shadow: 0 10px 24px rgba(17, 17, 17, 0.12);
  font-family: var(--resume-font-family, Arial, Helvetica, sans-serif);
  font-size: 13px;
  line-height: 1.28;
  text-align: left;
  hyphens: auto;
}

.resume-header {
  text-align: center;
}

.resume-header h1 {
  margin: 0;
  font-size: 2.5em;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  line-height: 1;
  margin-bottom: 0.25em;
  border-bottom: 1px solid darkgrey;
  padding-bottom: 0.08em;
}

.resume-contact-link,
.resume-contact-text,
.resume-contact-separator {
  color: inherit;
}

.resume-contact-link {
  text-decoration: none;
}

.resume-contact-link:hover {
  text-decoration: underline;
}

.resume-intro {
  max-width: 78ch;
  font-size: 12.5px;
  line-height: 1.28;
  margin: 0.35em auto 0;
  text-align: center;
}

.resume-body {
  padding-top: 4px;
}

.resume-meta-row {
  margin: 0.15em auto;
  font-size: 12px;
  line-height: 1.25;
  text-align: center;
}

.resume-meta-item,
.resume-meta-separator {
  display: inline-block;
  margin: 0 0.45em;
}

.resume-meta-item .iconify {
  vertical-align: -0.2em;
  margin-right: 0.28em;
}

.resume-meta-separator {
  margin: 0 0.45em;
}

.resume-section + .resume-section {
  margin-top: 2px;
}

.resume-section h2 {
  margin: 0.72em 0 0.3em;
  font-size: 1.2em;
  font-weight: 700;
  border-bottom: 1px solid darkgrey;
  padding-bottom: 0.04em;
  letter-spacing: 0;
  text-transform: none;
}

.resume-prose p,
.resume-bullets,
.timeline-extra,
.skill-row {
  margin: 0;
}

.resume-prose a,
.timeline-link a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 0.12em;
}

.resume-prose code {
  padding: 0.08rem 0.28rem;
  border: 1px solid rgba(17, 17, 17, 0.16);
  border-radius: 4px;
  background: #f5f5f5;
  font-family: "SF Mono", "Roboto Mono", monospace;
  font-size: 0.92em;
}

.timeline {
  display: grid;
  gap: 2px;
}

.timeline-row {
  break-inside: avoid;
}

.timeline-row-head {
  display: flex;
  margin: 0;
  gap: 0;
}

.timeline-row-head dt,
.timeline-row-head dd {
  margin: 0;
  font-size: 13px;
}

.timeline-row-head dt,
.timeline-row-head dd:not(:last-child) {
  flex: 1;
}

.timeline-row-head dt {
  text-align: left;
}

.timeline-row-head dt + dd {
  text-align: center;
  white-space: nowrap;
}

.timeline-link,
.timeline-extra,
.timeline-row .resume-prose,
.timeline-row .resume-bullets {
  margin-top: 1px;
}

.timeline-link {
  font-size: 12px;
}

.timeline-row-head dd:last-child {
  text-align: right;
  white-space: nowrap;
}

.timeline-row-head--education dt {
  text-align: left;
  flex: 1 1 auto;
}

.timeline-row-head--education dd:last-child {
  text-align: right;
  flex: 0 0 20%;
}

.resume-bullets {
  padding-left: 18px;
  margin: 0.15em 0 0.45em;
}

.resume-bullets li + li {
  margin-top: 1px;
}

.skills-table {
  display: grid;
  gap: 0.15em;
}

@media (max-width: 1080px) {
  .site-shell {
    width: min(100%, calc(100% - 20px));
    margin: 12px auto 28px;
  }

  .home-hero,
  .product-card {
    padding: 22px;
  }

  .workspace {
    grid-template-columns: 1fr;
  }

  .app-shell {
    width: min(100%, calc(100% - 20px));
    margin: 10px auto 24px;
  }

  .topbar,
  .panel {
    padding: 20px;
  }
}

@media (max-width: 720px) {
  .resume-paper {
    padding: 22px;
    min-height: auto;
  }

  .resume-header h1 {
    font-size: 24px;
  }

  .timeline-row-head {
    display: block;
  }

  .timeline-row-head dd {
    text-align: left;
    white-space: normal;
  }
}

@page {
  size: letter;
  margin: 0.2in;
}

@media print {
  body {
    background: #ffffff;
  }

  .topbar,
  .editor-panel,
  .parse-feedback,
  .panel-head {
    display: none !important;
  }

  .app-shell,
  .workspace,
  .preview-panel,
  .resume-stage {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 0;
    border: 0;
    box-shadow: none;
    background: #ffffff;
  }

  .resume-paper {
    width: auto;
    min-height: auto;
    margin: 0;
    padding: 0.45in 0.55in 0.55in;
    box-shadow: none;
    border: 0;
  }
}
