/* ==========================================================================
   STEFANIEGLAM — stefanierojas.com
   Style: High-Fashion Editorial Minimalist Luxury (Vogue / Atelier Aesthetic)
   Palette: Alabaster (#FAF9F7), Warm Stone (#F0ECE4), Obsidian Espresso (#161412),
            Muted Bronze (#9A744F), Hairline Border (#E3DDD3)
   ========================================================================== */

:root {
  --bg: #FAF9F7;
  --surface: #F0ECE4;
  --white: #FFFFFF;
  --ink: #161412;
  --muted: #6A635C;
  --accent: #9A744F;
  --line: #E3DDD3;
  --serif: 'Cormorant Garamond', Georgia, serif;
  --sans: 'Jost', system-ui, -apple-system, sans-serif;
}

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

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

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

button, input, select, textarea {
  font: inherit;
  color: inherit;
}

.wrap {
  width: 100%;
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 32px;
}

/* Announcement Strip */
.ribbon {
  background: var(--ink);
  color: #EAE4DA;
  font-size: 0.72rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  text-align: center;
  padding: 10px 16px;
}

/* Minimalist Editorial Header */
.atelier-header {
  position: sticky;
  top: 0;
  z-index: 90;
  background: rgba(250, 249, 247, 0.94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.header-grid {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  height: 78px;
  gap: 20px;
}

.nav-left {
  display: flex;
  gap: 26px;
  font-size: 0.76rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.nav-left a {
  position: relative;
  padding: 4px 0;
}

.nav-left a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 1px;
  background: var(--ink);
  transition: width 0.25s ease;
}

.nav-left a:hover::after {
  width: 100%;
}

.wordmark {
  font-family: var(--serif);
  font-size: 1.95rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-align: center;
  line-height: 1;
}

.wordmark small {
  display: block;
  font-family: var(--sans);
  font-size: 0.6rem;
  letter-spacing: 0.34em;
  color: var(--muted);
  margin-top: 4px;
}

.nav-right {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 22px;
  font-size: 0.76rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.bag-trigger {
  background: none;
  border: 1px solid var(--ink);
  padding: 9px 18px;
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}

.bag-trigger:hover {
  background: var(--ink);
  color: var(--bg);
}

.menu-mobile-btn {
  display: none;
  background: none;
  border: 1px solid var(--line);
  padding: 8px 12px;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
}

/* Editorial Split Hero */
.editorial-hero {
  border-bottom: 1px solid var(--line);
}

.hero-split {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  min-height: 82vh;
}

.hero-copy {
  padding: 72px 56px 72px 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border-right: 1px solid var(--line);
}

.eyebrow {
  font-size: 0.72rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 22px;
}

.hero-title {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(3rem, 5.4vw, 5.2rem);
  line-height: 0.96;
  letter-spacing: -0.015em;
  margin-bottom: 28px;
}

.hero-title em {
  font-style: italic;
  color: var(--accent);
}

.hero-desc {
  max-width: 460px;
  font-size: 0.98rem;
  color: var(--muted);
  margin-bottom: 36px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 48px;
}

.btn-atelier {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 15px 30px;
  font-size: 0.74rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  border: 1px solid var(--ink);
  cursor: pointer;
  transition: all 0.22s ease;
}

.btn-solid {
  background: var(--ink);
  color: var(--bg);
}

.btn-solid:hover {
  background: #302B27;
}

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

.btn-ghost:hover {
  background: var(--surface);
}

.hero-footnotes {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  padding-top: 26px;
  border-top: 1px solid var(--line);
}

.hero-footnotes div strong {
  display: block;
  font-family: var(--serif);
  font-size: 1.45rem;
  font-weight: 500;
  line-height: 1.1;
}

.hero-footnotes div span {
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

.hero-media {
  position: relative;
  background: var(--surface);
  overflow: hidden;
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

.hero-plate {
  position: absolute;
  left: 28px;
  bottom: 28px;
  background: rgba(250, 249, 247, 0.92);
  backdrop-filter: blur(8px);
  border: 1px solid var(--line);
  padding: 16px 20px;
  max-width: 280px;
}

.hero-plate span {
  display: block;
  font-size: 0.66rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
}

.hero-plate strong {
  font-family: var(--serif);
  font-size: 1.2rem;
  font-weight: 500;
}

/* Sections */
.block {
  padding: 86px 0;
  border-bottom: 1px solid var(--line);
}

.block-stone {
  background: var(--surface);
}

.block-header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  margin-bottom: 44px;
}

.block-title {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2.2rem, 3.8vw, 3.4rem);
  line-height: 1.02;
}

.block-title em {
  font-style: italic;
  color: var(--accent);
}

/* Catalog Filter Bar */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  padding: 18px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  margin-bottom: 40px;
}

.filter-cats {
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
}

.filter-cat {
  background: none;
  border: none;
  padding: 4px 0;
  font-size: 0.76rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  cursor: pointer;
  border-bottom: 1.5px solid transparent;
  transition: all 0.2s ease;
}

.filter-cat:hover, .filter-cat.active {
  color: var(--ink);
  border-bottom-color: var(--ink);
}

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

.select-minimal {
  background: transparent;
  border: 1px solid var(--line);
  padding: 9px 14px;
  font-size: 0.76rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
}

/* Product Gallery */
.product-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 36px 24px;
}

.piece-card {
  display: flex;
  flex-direction: column;
}

.piece-media {
  position: relative;
  aspect-ratio: 3 / 4;
  background: var(--surface);
  overflow: hidden;
  margin-bottom: 14px;
  cursor: pointer;
}

.piece-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.65s cubic-bezier(0.22, 1, 0.36, 1);
}

.piece-card:hover .piece-media img {
  transform: scale(1.05);
}

.piece-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  background: rgba(250, 249, 247, 0.92);
  padding: 4px 10px;
  font-size: 0.64rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  border: 1px solid var(--line);
}

.quick-overlay {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 12px;
  background: rgba(22, 20, 18, 0.9);
  color: var(--bg);
  text-align: center;
  padding: 11px;
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  opacity: 0;
  transform: translateY(8px);
  transition: all 0.25s ease;
  border: none;
  cursor: pointer;
}

.piece-card:hover .quick-overlay {
  opacity: 1;
  transform: translateY(0);
}

.piece-meta {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 4px;
}

.piece-cat {
  font-size: 0.66rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}

.piece-price {
  font-size: 0.9rem;
  font-weight: 500;
  letter-spacing: 0.04em;
}

.piece-name {
  font-family: var(--serif);
  font-size: 1.22rem;
  font-weight: 500;
  line-height: 1.2;
  margin-bottom: 6px;
}

.piece-sizes {
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: 0.08em;
}

/* Editorial Lookbook / Story */
.story-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 64px;
  align-items: center;
}

.story-images {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.story-images img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

.story-images img:last-child {
  margin-top: 40px;
}

.story-pillars {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-top: 32px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
}

.story-pillars h4 {
  font-family: var(--serif);
  font-size: 1.3rem;
  font-weight: 500;
  margin-bottom: 6px;
}

.story-pillars p {
  font-size: 0.88rem;
  color: var(--muted);
}

/* Shipping & Trust Strip */
.promises-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  border: 1px solid var(--line);
  background: var(--white);
}

.promise-cell {
  padding: 36px 30px;
  border-right: 1px solid var(--line);
}

.promise-cell:last-child {
  border-right: none;
}

.promise-num {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.4rem;
  color: var(--accent);
  margin-bottom: 10px;
}

.promise-cell h3 {
  font-family: var(--serif);
  font-size: 1.45rem;
  font-weight: 500;
  margin-bottom: 8px;
}

.promise-cell p {
  font-size: 0.88rem;
  color: var(--muted);
}

/* Footer */
.atelier-footer {
  background: var(--ink);
  color: #DDD5CA;
  padding: 72px 0 34px;
}

.footer-cols {
  display: grid;
  grid-template-columns: 1.3fr 0.9fr 1fr 1.3fr;
  gap: 40px;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.footer-cols h5 {
  font-size: 0.7rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #C7A47D;
  margin-bottom: 16px;
}

.footer-cols a, .footer-cols p {
  display: block;
  font-size: 0.86rem;
  color: #CFC7BC;
  margin-bottom: 9px;
}

.footer-cols a:hover {
  color: #FFFFFF;
}

.footer-base {
  padding-top: 24px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  color: #9A9187;
}

/* Quick View Modal */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(22, 20, 18, 0.55);
  z-index: 150;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-backdrop.open {
  display: flex;
}

.qv-modal {
  background: var(--bg);
  border: 1px solid var(--line);
  max-width: 880px;
  width: 100%;
  max-height: 92vh;
  overflow-y: auto;
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  position: relative;
}

.qv-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px;
  height: 36px;
  background: var(--bg);
  border: 1px solid var(--line);
  cursor: pointer;
  z-index: 5;
}

.qv-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  min-height: 380px;
}

.qv-body {
  padding: 36px 32px;
  display: flex;
  flex-direction: column;
}

.qv-body h3 {
  font-family: var(--serif);
  font-size: 2rem;
  font-weight: 400;
  line-height: 1.05;
  margin: 8px 0 10px;
}

.qv-price {
  font-size: 1.15rem;
  font-weight: 500;
  margin-bottom: 18px;
}

.qv-desc {
  font-size: 0.9rem;
  color: var(--muted);
  margin-bottom: 22px;
}

.size-picker {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0 22px;
}

.size-opt {
  min-width: 46px;
  padding: 9px 12px;
  border: 1px solid var(--line);
  background: var(--white);
  font-size: 0.76rem;
  letter-spacing: 0.1em;
  cursor: pointer;
}

.size-opt.selected {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}

.size-guide {
  margin-top: 18px;
  border-top: 1px solid var(--line);
  padding-top: 14px;
  font-size: 0.78rem;
  color: var(--muted);
}

/* Shopping Bag Drawer */
.bag-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(22, 20, 18, 0.45);
  z-index: 160;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.bag-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}

.bag-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(460px, 100%);
  background: var(--bg);
  border-left: 1px solid var(--line);
  z-index: 170;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.28s ease;
}

.bag-drawer.open {
  transform: translateX(0);
}

.bag-head {
  padding: 24px 28px;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.bag-head h3 {
  font-family: var(--serif);
  font-size: 1.65rem;
  font-weight: 400;
}

.bag-body {
  padding: 24px 28px;
  flex: 1;
  overflow-y: auto;
}

.bag-row {
  display: grid;
  grid-template-columns: 64px 1fr auto;
  gap: 14px;
  padding-bottom: 16px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--line);
  align-items: center;
}

.bag-row img {
  width: 64px;
  height: 82px;
  object-fit: cover;
}

.bag-row h4 {
  font-family: var(--serif);
  font-size: 1.08rem;
  font-weight: 500;
}

.bag-row small {
  display: block;
  font-size: 0.74rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.qty-mini {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
}

.qty-mini button {
  width: 24px;
  height: 24px;
  border: 1px solid var(--line);
  background: var(--white);
  cursor: pointer;
}

.bag-form {
  margin-top: 20px;
  display: grid;
  gap: 12px;
}

.bag-form label {
  display: block;
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 4px;
}

.bag-form input, .bag-form select, .bag-form textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--line);
  background: var(--white);
  font-size: 0.88rem;
}

.bag-foot {
  padding: 20px 28px 26px;
  border-top: 1px solid var(--line);
  background: var(--surface);
}

.bag-line {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  margin-bottom: 6px;
}

.bag-total {
  display: flex;
  justify-content: space-between;
  font-family: var(--serif);
  font-size: 1.55rem;
  padding-top: 10px;
  margin-top: 8px;
  border-top: 1px solid var(--line);
}

.order-done {
  background: var(--surface);
  border: 1px solid var(--accent);
  padding: 22px;
}

.order-done h4 {
  font-family: var(--serif);
  font-size: 1.5rem;
  margin-bottom: 8px;
}

.atelier-toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translate(-50%, 80px);
  background: var(--ink);
  color: var(--bg);
  padding: 12px 24px;
  font-size: 0.74rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  z-index: 220;
  transition: transform 0.25s ease;
}

.atelier-toast.show {
  transform: translate(-50%, 0);
}

/* Legal pages */
.legal-article {
  max-width: 820px;
  margin: 0 auto;
}

.legal-article h1 {
  font-family: var(--serif);
  font-size: 2.8rem;
  font-weight: 400;
  margin-bottom: 18px;
}

.legal-article h2 {
  font-family: var(--serif);
  font-size: 1.55rem;
  font-weight: 500;
  margin: 28px 0 8px;
}

.legal-article p, .legal-article li {
  color: var(--muted);
  font-size: 0.95rem;
  margin-bottom: 10px;
}

.legal-article ul {
  padding-left: 20px;
}

@media (max-width: 1100px) {
  .product-grid { grid-template-columns: repeat(3, 1fr); }
  .footer-cols { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 880px) {
  .wrap { padding: 0 20px; }
  .header-grid { grid-template-columns: auto 1fr auto; }
  .nav-left {
    display: none;
    position: absolute;
    top: 78px;
    left: 0;
    right: 0;
    background: var(--bg);
    border-bottom: 1px solid var(--line);
    padding: 18px 20px;
    flex-direction: column;
    gap: 14px;
  }
  .nav-left.open { display: flex; }
  .menu-mobile-btn { display: inline-block; }
  .hero-split, .story-grid, .qv-modal { grid-template-columns: 1fr; }
  .hero-copy { padding: 48px 0; border-right: none; border-bottom: 1px solid var(--line); }
  .hero-media { min-height: 460px; }
  .product-grid { grid-template-columns: repeat(2, 1fr); }
  .promises-grid { grid-template-columns: 1fr; }
  .promise-cell { border-right: none; border-bottom: 1px solid var(--line); }
  .promise-cell:last-child { border-bottom: none; }
}

@media (max-width: 540px) {
  .product-grid, .footer-cols, .story-pillars, .hero-footnotes { grid-template-columns: 1fr; }
}
