/* ============================================
   Justine Bevilacqua — Portfolio
   Brand: This Optimistic Life palette
   ============================================ */

:root {
  --terracotta: #e75628;
  --terracotta-dark: #c94820;
  --gold: #eeac55;
  --blush: #f8e1cf;
  --blush-pale: #fbede1;
  --cream: #f2f1ed;
  --ink: #333333;
  --ink-soft: #5a5551;
  --heading: 'Playfair Display', Georgia, serif;
  --body: 'Lora', Georgia, serif;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--ink);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { font-family: var(--heading); font-weight: 500; line-height: 1.15; }

.container { max-width: 1080px; margin: 0 auto; padding: 0 1.5rem; }
.container.narrow { max-width: 760px; }

/* ---------- Nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 100;
  background: rgba(242, 241, 237, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(51, 51, 51, 0.08);
}
.nav-inner {
  max-width: 1080px; margin: 0 auto; padding: 0.9rem 1.5rem;
  display: flex; align-items: center; justify-content: space-between;
}
.nav-name {
  font-family: var(--heading); font-size: 1.15rem;
  color: var(--ink); text-decoration: none;
}
.nav-links { display: flex; align-items: center; gap: 1.4rem; }
.nav-links a {
  color: var(--ink); text-decoration: none;
  font-size: 0.95rem; font-weight: 500;
}
.nav-links a:hover { color: var(--terracotta); }
.nav-cta {
  background: var(--terracotta); color: #fff !important;
  padding: 0.4rem 1rem; border-radius: 999px;
}
.nav-cta:hover { background: var(--terracotta-dark); }

/* ---------- Hero ---------- */
.hero {
  background: var(--ink);
  color: var(--cream);
  padding: 6rem 0 6.5rem;
  position: relative;
  overflow: hidden;
}
.hero::after {
  content: '';
  position: absolute; right: -180px; top: -180px;
  width: 520px; height: 520px; border-radius: 50%;
  background: radial-gradient(circle, rgba(231, 86, 40, 0.28), transparent 68%);
  pointer-events: none;
}
.hero-kicker {
  font-weight: 600; font-size: 0.8rem;
  text-transform: uppercase; letter-spacing: 0.14em;
  color: var(--gold); margin-bottom: 1.4rem;
}
.hero h1 {
  font-size: clamp(2.3rem, 6vw, 4rem);
  color: #fff; margin-bottom: 1.4rem;
}
.hero-sub {
  max-width: 620px; font-size: 1.15rem;
  color: rgba(242, 241, 237, 0.85); margin-bottom: 2.4rem;
}
.hero-ctas { display: flex; gap: 1rem; flex-wrap: wrap; }

.btn {
  display: inline-block; text-decoration: none;
  font-family: var(--body); font-weight: 600; font-size: 1rem;
  padding: 0.8rem 1.8rem; border-radius: 999px;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.btn-primary { background: var(--terracotta); color: #fff; }
.btn-primary:hover { background: var(--terracotta-dark); }
.btn-ghost {
  color: var(--cream); border: 1.5px solid rgba(242, 241, 237, 0.5);
}
.btn-ghost:hover { border-color: var(--gold); color: var(--gold); }

/* ---------- Sections ---------- */
.section { padding: 5rem 0; }
.section-label {
  font-weight: 600; font-size: 0.8rem;
  text-transform: uppercase; letter-spacing: 0.14em;
  color: var(--terracotta); margin-bottom: 0.8rem;
}
.section-label.light { color: var(--gold); }
.section h2 {
  font-size: clamp(1.9rem, 4.5vw, 2.7rem);
  margin-bottom: 1.4rem;
}
.lede { font-size: 1.1rem; }
.section-intro { max-width: 640px; margin-bottom: 2.2rem; color: var(--ink-soft); }

/* ---------- Numbers ---------- */
.numbers-section { background: var(--blush); padding: 3.5rem 0; }
.numbers {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 2rem;
  text-align: center;
}
.number-item { display: flex; flex-direction: column; gap: 0.3rem; }
.number {
  font-family: var(--heading); font-size: 3rem;
  color: var(--terracotta); line-height: 1;
}
.number-label { font-size: 0.9rem; color: var(--ink-soft); }

/* ---------- Filters ---------- */
.filters { display: flex; gap: 0.6rem; flex-wrap: wrap; margin-bottom: 2rem; }
.filter-btn {
  font-family: var(--body); font-weight: 600; font-size: 0.88rem;
  padding: 0.45rem 1.1rem; border-radius: 999px;
  border: 1.5px solid rgba(51, 51, 51, 0.22);
  background: transparent; color: var(--ink); cursor: pointer;
  transition: all 0.2s ease;
}
.filter-btn:hover { border-color: var(--terracotta); color: var(--terracotta); }
.filter-btn.active {
  background: var(--terracotta); border-color: var(--terracotta); color: #fff;
}

/* ---------- Project grid ---------- */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.4rem;
}
.card {
  background: var(--blush-pale);
  border: 1px solid rgba(51, 51, 51, 0.07);
  border-radius: 14px;
  padding: 1.6rem;
  display: flex; flex-direction: column; gap: 0.8rem;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 28px rgba(51, 51, 51, 0.09);
}
.card.featured { border-top: 3px solid var(--gold); }
.card-category {
  font-size: 0.72rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.12em;
  color: var(--terracotta);
}
.card h3 { font-size: 1.35rem; }
.card-desc { font-size: 0.96rem; color: var(--ink-soft); flex-grow: 1; }
.card-tags { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.tag {
  font-size: 0.72rem; font-weight: 600;
  padding: 0.22rem 0.7rem; border-radius: 999px;
  background: var(--blush); color: var(--ink);
}
.card-toggle {
  font-family: var(--body); font-weight: 600; font-size: 0.88rem;
  color: var(--terracotta); background: none; border: none;
  cursor: pointer; text-align: left; padding: 0;
}
.card-toggle:hover { color: var(--terracotta-dark); text-decoration: underline; }
.card-details {
  display: none;
  font-size: 0.94rem; color: var(--ink);
  border-top: 1px solid rgba(51, 51, 51, 0.1);
  padding-top: 0.9rem;
}
.card.open .card-details { display: block; }
.card-link {
  display: inline-block; margin-top: 0.6rem;
  font-weight: 600; color: var(--terracotta); text-decoration: none;
}
.card-link:hover { text-decoration: underline; }

/* ---------- How I work ---------- */
.how-section { background: var(--blush-pale); }
.steps { list-style: none; margin: 2.4rem 0; display: flex; flex-direction: column; gap: 1.8rem; }
.steps li { display: flex; gap: 1.3rem; align-items: flex-start; }
.step-num {
  font-family: var(--heading); font-size: 1.5rem;
  color: var(--gold); min-width: 2.6rem; line-height: 1.3;
}
.steps h3 { font-size: 1.25rem; margin-bottom: 0.25rem; }
.steps p { font-size: 0.98rem; color: var(--ink-soft); }
.stack { margin-top: 2.6rem; }
.stack-label {
  font-weight: 600; font-size: 0.8rem;
  text-transform: uppercase; letter-spacing: 0.14em;
  color: var(--terracotta); margin-bottom: 0.8rem;
}
.stack-list { list-style: none; display: flex; flex-wrap: wrap; gap: 0.6rem; }
.stack-list li {
  background: var(--cream); border: 1px solid rgba(51, 51, 51, 0.1);
  padding: 0.35rem 1rem; border-radius: 999px;
  font-size: 0.9rem; font-weight: 600;
}

/* ---------- Contact ---------- */
.contact-section { background: var(--ink); color: var(--cream); }
.contact-section h2 { color: #fff; }
.contact-section .lede { color: rgba(242, 241, 237, 0.85); }
.contact-links {
  display: flex; align-items: center; gap: 1.6rem;
  flex-wrap: wrap; margin-top: 2.2rem;
}
.contact-link { color: var(--gold); text-decoration: none; font-weight: 600; }
.contact-link:hover { text-decoration: underline; }

/* ---------- Footer ---------- */
.footer {
  background: var(--ink); color: rgba(242, 241, 237, 0.55);
  padding: 1.6rem 0; font-size: 0.85rem;
  border-top: 1px solid rgba(242, 241, 237, 0.12);
}

/* ---------- Responsive ---------- */
@media (max-width: 820px) {
  .numbers { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .section { padding: 3.5rem 0; }
  .hero { padding: 4rem 0 4.5rem; }
  .desktop-break { display: none; }
  .nav-links { gap: 0.9rem; }
  .nav-links a:not(.nav-cta) { display: none; }
  .numbers { gap: 1.4rem; }
  .number { font-size: 2.3rem; }
  .steps li { gap: 0.9rem; }
}
