/* Soft Gold — alirajabi.com */

/* Self-hosted fonts (variable weight files, no external CDN) */
@font-face {
  font-family: "Cormorant Garamond";
  font-style: normal;
  font-weight: 500 700;
  font-display: swap;
  src: url("../fonts/cormorant-garamond-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Cormorant Garamond";
  font-style: normal;
  font-weight: 500 700;
  font-display: swap;
  src: url("../fonts/cormorant-garamond-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Outfit";
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url("../fonts/outfit-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Outfit";
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url("../fonts/outfit-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --bg: #26231e;
  --bg-elevated: #2e2a24;
  --surface: #353028;
  --text: #f4f1ea;
  --muted: #b0aaa0;
  --accent: #c9a227;
  --accent-soft: rgba(201, 162, 39, 0.14);
  --border: #4a4338;
  --danger: #d4786a;
  --ok: #8a9a7b;
  --font-display: "Cormorant Garamond", "Times New Roman", serif;
  --font-body: "Outfit", "Segoe UI", sans-serif;
  --space: clamp(1rem, 2.5vw, 2rem);
  --max: 68rem;
  --header-h: 4.25rem;
  --radius: 0.35rem;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 0.75rem);
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .reveal {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-body);
  font-weight: 400;
  font-size: clamp(1rem, 0.95rem + 0.2vw, 1.0625rem);
  line-height: 1.65;
  color: var(--text);
  background:
    radial-gradient(1200px 600px at 10% -10%, rgba(201, 162, 39, 0.08), transparent 55%),
    radial-gradient(900px 500px at 100% 0%, rgba(242, 239, 232, 0.04), transparent 50%),
    var(--bg);
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
  transition: color 0.2s var(--ease);
}

a:hover {
  color: #e0bc4a;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 100;
  padding: 0.6rem 1rem;
  background: var(--accent);
  color: #1c1a17;
  font-weight: 600;
  text-decoration: none;
  border-radius: var(--radius);
}

.skip-link:focus {
  top: 1rem;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  display: flex;
  align-items: center;
  border-bottom: 1px solid transparent;
  background: rgba(38, 35, 30, 0.78);
  backdrop-filter: blur(12px);
  transition: border-color 0.25s var(--ease), background 0.25s var(--ease);
}

.site-header.is-scrolled {
  border-bottom-color: var(--border);
  background: rgba(38, 35, 30, 0.94);
}

.header-inner {
  width: min(100% - 2 * var(--space), var(--max));
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--text);
  text-decoration: none;
}

.brand:hover {
  color: var(--accent);
}

.nav-toggle {
  display: none;
  width: 2.75rem;
  height: 2.75rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 1.1rem;
  height: 1.5px;
  margin: 0.28rem auto;
  background: currentColor;
}

.site-nav ul {
  display: flex;
  gap: 0.15rem 1.25rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.site-nav a:hover,
.site-nav a.is-active {
  color: var(--accent);
}

main {
  display: block;
}

.section {
  width: min(100% - 2 * var(--space), var(--max));
  margin-inline: auto;
  padding: clamp(3.5rem, 8vw, 6rem) 0;
}

.section + .section {
  border-top: 1px solid var(--border);
}

.section-label {
  margin: 0 0 0.75rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}

.section h2 {
  margin: 0 0 1.25rem;
  font-family: var(--font-display);
  font-size: clamp(2rem, 1.5rem + 1.8vw, 2.75rem);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: 0.01em;
}

.section-lead {
  max-width: 36rem;
  margin: 0 0 2rem;
  color: var(--muted);
}

/* Hero */
.hero {
  min-height: auto;
  display: grid;
  align-items: center;
  padding-block: clamp(2.25rem, 5vw, 3.5rem) clamp(2.5rem, 6vw, 4rem);
  border-top: none;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: clamp(1.5rem, 4vw, 2.75rem);
  align-items: center;
}

.hero-kicker {
  margin: 0 0 1rem;
  color: var(--accent);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero h1 {
  margin: 0 0 0.65rem;
  font-family: var(--font-display);
  font-size: clamp(3rem, 2.2rem + 3.5vw, 4.75rem);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: 0.01em;
}

.hero-role {
  margin: 0 0 1.25rem;
  font-size: clamp(1.15rem, 1rem + 0.6vw, 1.4rem);
  color: var(--muted);
  font-weight: 400;
}

.hero-brief {
  margin: 0 0 2rem;
  max-width: 34rem;
  color: var(--text);
  opacity: 0.92;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.85rem;
}

.social-icons {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
}

.social-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.85rem;
  height: 2.85rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--text);
  text-decoration: none;
  transition: border-color 0.2s var(--ease), color 0.2s var(--ease), background 0.2s var(--ease);
}

.social-icon:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.social-icon svg {
  width: 1.25rem;
  height: 1.25rem;
  fill: currentColor;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 2.85rem;
  padding: 0.7rem 1.25rem;
  border-radius: var(--radius);
  border: 1px solid transparent;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.2s var(--ease), border-color 0.2s var(--ease), color 0.2s var(--ease),
    transform 0.2s var(--ease);
}

.btn:active {
  transform: translateY(1px);
}

.btn-primary {
  background: var(--accent);
  color: #1c1a17;
}

.btn-primary:hover {
  background: #e0bc4a;
  color: #1c1a17;
}

.btn-ghost {
  background: transparent;
  border-color: var(--border);
  color: var(--text);
}

.btn-ghost:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.hero-photo {
  position: relative;
  justify-self: end;
  width: 15rem;
  flex-shrink: 0;
}

.hero-photo::before {
  content: "";
  position: absolute;
  inset: -0.35rem;
  border: 1px solid var(--accent);
  opacity: 0.45;
  border-radius: 50%;
  z-index: 0;
}

.hero-photo img {
  position: relative;
  z-index: 1;
  width: 15rem;
  height: 15rem;
  aspect-ratio: 1;
  object-fit: cover;
  object-position: center 18%;
  border-radius: 50%;
  border: 2px solid var(--border);
  filter: saturate(0.95) contrast(1.02);
}

/* Profile */
.profile-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(1.5rem, 4vw, 2.5rem);
}

.profile-card {
  padding: 1.5rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.profile-card h3 {
  margin: 0 0 1rem;
  font-family: var(--font-display);
  font-size: 1.55rem;
  font-weight: 600;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.tag-list li {
  padding: 0.4rem 0.7rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--text);
  font-size: 0.88rem;
}

.lead-list {
  margin: 0;
  padding-left: 1.1rem;
  color: var(--muted);
}

.lead-list li + li {
  margin-top: 0.55rem;
}

/* Experience */
.exp-group {
  margin-bottom: 2rem;
}

.exp-group:last-child {
  margin-bottom: 0;
}

.exp-company {
  margin: 0 0 0.85rem;
  font-family: var(--font-display);
  font-size: 1.55rem;
  font-weight: 600;
  color: var(--text);
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 0.85rem;
}

.exp-sub {
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--muted);
}

.timeline {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.75rem;
}

.timeline li {
  display: grid;
  gap: 0.35rem;
  padding: 1.05rem 1.2rem;
  border-left: 2px solid var(--accent);
  background: linear-gradient(90deg, var(--accent-soft), transparent 55%);
  border-radius: 0 var(--radius) var(--radius) 0;
}

.timeline-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem 0.75rem;
}

.timeline h4 {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 600;
}

.role-tag {
  display: inline-flex;
  align-items: center;
  padding: 0.15rem 0.55rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border: 1px solid var(--border);
}

.role-tag-tech {
  color: var(--accent);
  background: var(--accent-soft);
}

.role-tag-lead {
  color: var(--text);
  background: rgba(242, 239, 232, 0.06);
}

.timeline p {
  margin: 0;
  color: var(--muted);
  max-width: 44rem;
  font-size: 0.95rem;
}

/* Work */
.work-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1rem;
}

.work-list li {
  padding: 1.35rem 0;
  border-bottom: 1px solid var(--border);
}

.work-list li:first-child {
  padding-top: 0;
}

.work-list h3 {
  margin: 0 0 0.4rem;
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 600;
}

.work-list p {
  margin: 0;
  color: var(--muted);
  max-width: 40rem;
}

/* Contact */
.contact-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: clamp(1.75rem, 4vw, 3rem);
  align-items: start;
}

.contact-form {
  display: grid;
  gap: 1rem;
}

.form-row {
  display: grid;
  gap: 0.4rem;
}

.form-row label {
  font-size: 0.88rem;
  color: var(--muted);
}

.form-row input,
.form-row textarea {
  width: 100%;
  padding: 0.8rem 0.9rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--text);
  font: inherit;
}

.form-row input::placeholder,
.form-row textarea::placeholder {
  color: #7d786e;
}

.form-row textarea {
  min-height: 9rem;
  resize: vertical;
}

.hp {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.form-status {
  min-height: 1.4rem;
  margin: 0;
  font-size: 0.92rem;
}

.form-status.is-ok {
  color: var(--ok);
}

.form-status.is-error {
  color: var(--danger);
}

.contact-aside {
  padding: 1.5rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-elevated);
}

.contact-aside p {
  margin: 0 0 1.25rem;
  color: var(--muted);
}

.site-footer {
  border-top: 1px solid var(--border);
  padding: 1.75rem var(--space);
  color: var(--muted);
  font-size: 0.88rem;
}

.footer-inner {
  width: min(100%, var(--max));
  margin-inline: auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem;
}

.reveal {
  opacity: 0;
  transform: translateY(0.75rem);
  transition: opacity 0.55s var(--ease), transform 0.55s var(--ease);
}

.reveal.is-in {
  opacity: 1;
  transform: none;
}

@media (max-width: 860px) {
  .hero-grid,
  .profile-grid,
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .hero-photo {
    justify-self: start;
    order: -1;
  }

  .hero-photo,
  .hero-photo img {
    width: 12.5rem;
    height: 12.5rem;
  }

  .nav-toggle {
    display: inline-block;
  }

  .site-nav {
    position: absolute;
    top: var(--header-h);
    left: 0;
    right: 0;
    padding: 1rem var(--space) 1.25rem;
    background: rgba(38, 35, 30, 0.97);
    border-bottom: 1px solid var(--border);
    transform: translateY(-120%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.25s var(--ease), opacity 0.25s var(--ease);
  }

  .site-nav.is-open {
    transform: none;
    opacity: 1;
    pointer-events: auto;
  }

  .site-nav ul {
    flex-direction: column;
    gap: 0.85rem;
  }
}
