/* ===========================================================
   Danielle M. Araneta — personal site
   Light, professional theme. Plain CSS, no build step.
   =========================================================== */

:root {
  --bg:        #ffffff;
  --bg-alt:    #f6f8fc;
  --surface:   #ffffff;
  --text:      #0f172a;   /* slate-900 */
  --muted:     #51607a;   /* slate-ish */
  --border:    #e6eaf1;
  --accent:    #2563eb;   /* blue-600 */
  --accent-d:  #1d4ed8;   /* blue-700 */
  --accent-sf: #eaf1ff;   /* accent soft */
  --shadow:    0 1px 2px rgba(15,23,42,.04), 0 8px 24px rgba(15,23,42,.06);
  --shadow-lg: 0 12px 40px rgba(15,23,42,.12);
  --radius:    16px;
  --maxw:      1080px;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

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

body {
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: inherit; text-decoration: none; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

/* ----------------------- NAV ----------------------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.82);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .25s ease, box-shadow .25s ease;
}
.nav.is-scrolled { border-color: var(--border); box-shadow: var(--shadow); }
.nav__inner { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.nav__brand { font-weight: 800; letter-spacing: -.01em; font-size: 1.05rem; }
.nav__links { display: flex; align-items: center; gap: 28px; }
.nav__links a { color: var(--muted); font-weight: 500; font-size: .95rem; transition: color .2s; }
.nav__links a:hover { color: var(--text); }
.nav__cta {
  background: var(--accent); color: #fff !important; padding: 8px 16px;
  border-radius: 999px; font-weight: 600 !important;
}
.nav__cta:hover { background: var(--accent-d); }
.nav__toggle { display: none; flex-direction: column; gap: 5px; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav__toggle span { width: 22px; height: 2px; background: var(--text); border-radius: 2px; transition: .25s; }

/* ----------------------- HERO ----------------------- */
.hero {
  position: relative;
  padding: 96px 0 80px;
  background:
    radial-gradient(1100px 480px at 78% -8%, var(--accent-sf), transparent 60%),
    linear-gradient(180deg, #fbfcff 0%, var(--bg) 100%);
}
.hero__eyebrow {
  color: var(--accent-d); font-weight: 600; font-size: .92rem;
  letter-spacing: .02em; margin-bottom: 18px;
}
.hero__title {
  font-size: clamp(2.1rem, 5vw, 3.5rem);
  line-height: 1.1; letter-spacing: -.025em; font-weight: 800;
  max-width: 18ch;
}
.hero__title span { color: var(--accent); }
.hero__lead {
  margin-top: 22px; max-width: 60ch;
  font-size: 1.13rem; color: var(--muted);
}
.hero__actions { margin-top: 32px; display: flex; flex-wrap: wrap; gap: 14px; }
.hero__links {
  margin-top: 34px; display: flex; flex-wrap: wrap; gap: 22px;
  font-size: .95rem; font-weight: 500;
}
.hero__links a { color: var(--muted); border-bottom: 1px solid transparent; padding-bottom: 2px; transition: .2s; }
.hero__links a:hover { color: var(--accent-d); border-color: var(--accent-d); }

/* ----------------------- BUTTONS ----------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 12px 22px; border-radius: 999px; font-weight: 600; font-size: .97rem;
  transition: transform .15s ease, background .2s ease, box-shadow .2s ease, border-color .2s;
  border: 1px solid transparent; cursor: pointer;
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--accent); color: #fff; box-shadow: var(--shadow); }
.btn--primary:hover { background: var(--accent-d); box-shadow: var(--shadow-lg); }
.btn--ghost { background: #fff; color: var(--text); border-color: var(--border); }
.btn--ghost:hover { border-color: var(--accent); color: var(--accent-d); }

/* ----------------------- SECTIONS ----------------------- */
.section { padding: 84px 0; }
.section--alt { background: var(--bg-alt); }
.section__head { margin-bottom: 44px; }
.section__title { font-size: clamp(1.6rem, 3vw, 2.1rem); font-weight: 800; letter-spacing: -.02em; }
.section__sub { margin-top: 10px; color: var(--muted); font-size: 1.05rem; }

/* ----------------------- PROJECTS ----------------------- */
.projects { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px; }
.card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow);
  display: flex; flex-direction: column;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: #d6e0f5; }

.card__media {
  position: relative; display: block; aspect-ratio: 16 / 9; overflow: hidden;
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--ph) 90%, #000 0%), color-mix(in srgb, var(--ph) 55%, #fff 0%));
}
.card__media img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  transition: transform .4s ease;
}
.card:hover .card__media img { transform: scale(1.04); }
.card__media img.is-missing { display: none; }      /* hide broken image, show gradient + label */
.card__media-label {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 700; font-size: 1.4rem; letter-spacing: .01em;
  opacity: 0; transition: opacity .2s; pointer-events: none;
  text-shadow: 0 2px 12px rgba(0,0,0,.25);
}
/* when img is missing, the gradient shows and we reveal the label */
.card__media img.is-missing ~ .card__media-label { opacity: .92; }

.card__body { padding: 22px 24px 26px; display: flex; flex-direction: column; gap: 12px; flex: 1; }
.card__titlerow { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.card__title { font-size: 1.22rem; font-weight: 700; letter-spacing: -.01em; }
.card__link { color: var(--accent-d); font-size: .85rem; font-weight: 600; white-space: nowrap; }
.card__link:hover { text-decoration: underline; }
.card__desc { color: var(--muted); font-size: .98rem; }
.badge {
  font-size: .66rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em;
  color: var(--accent-d); background: var(--accent-sf); padding: 3px 8px; border-radius: 6px;
  vertical-align: middle; margin-left: 6px;
}

/* ----------------------- TAGS ----------------------- */
.tags { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; margin-top: auto; }
.tags li {
  font-size: .8rem; font-weight: 500; color: var(--muted);
  background: var(--bg-alt); border: 1px solid var(--border);
  padding: 4px 11px; border-radius: 999px;
}
.tags--lg li { font-size: .9rem; padding: 6px 14px; }

/* ----------------------- TIMELINE ----------------------- */
.timeline { display: flex; flex-direction: column; gap: 8px; }
.tl {
  display: grid; grid-template-columns: 200px 1fr; gap: 24px;
  padding: 24px 0; border-top: 1px solid var(--border);
}
.tl:first-child { border-top: 0; }
.tl__meta { color: var(--muted); font-weight: 600; font-size: .92rem; padding-top: 3px; }
.tl__body h3 { font-size: 1.15rem; font-weight: 700; }
.tl__org { color: var(--muted); font-weight: 500; }
.tl__body p { margin-top: 8px; color: var(--muted); }

/* ----------------------- ABOUT ----------------------- */
.about { display: grid; grid-template-columns: 1.3fr 1fr; gap: 56px; align-items: start; }
.about__text p { color: var(--muted); margin-top: 16px; max-width: 56ch; }
.about__text .section__title { margin-bottom: 4px; }
.about__skills h3 { font-size: 1rem; font-weight: 700; margin-bottom: 16px; color: var(--text); }

/* ----------------------- CONTACT ----------------------- */
.contact { text-align: center; }
.contact__lead { color: var(--muted); font-size: 1.1rem; margin: 14px auto 28px; max-width: 48ch; }
.contact__actions { display: flex; justify-content: center; flex-wrap: wrap; gap: 14px; }
.contact__links { margin-top: 24px; color: var(--muted); display: flex; gap: 12px; justify-content: center; }
.contact__links a { font-weight: 600; }
.contact__links a:hover { color: var(--accent-d); }

/* ----------------------- FOOTER ----------------------- */
.footer { padding: 32px 0; border-top: 1px solid var(--border); color: var(--muted); font-size: .9rem; }

/* ----------------------- REVEAL ANIMATION ----------------------- */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-visible { opacity: 1; transform: none; }

/* ----------------------- RESPONSIVE ----------------------- */
@media (max-width: 860px) {
  .projects { grid-template-columns: 1fr; }
  .about { grid-template-columns: 1fr; gap: 36px; }
  .tl { grid-template-columns: 1fr; gap: 6px; }
  .tl__meta { padding-top: 0; }

  .nav__toggle { display: flex; }
  .nav__links {
    position: absolute; top: 64px; left: 0; right: 0;
    flex-direction: column; align-items: flex-start; gap: 4px;
    background: #fff; border-bottom: 1px solid var(--border);
    padding: 12px 24px 20px; box-shadow: var(--shadow);
    transform: translateY(-12px); opacity: 0; pointer-events: none; transition: .22s ease;
  }
  .nav__links a { padding: 10px 0; width: 100%; }
  .nav__links.is-open { transform: none; opacity: 1; pointer-events: auto; }
  .nav__cta { margin-top: 6px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
}
