/* Ana Mariposa Jewelry — "Vuelo" direction.
   Layout: ivory page, centered logo masthead, photo-led galleries; color comes from the stones, not the chrome.
   Deliberately a single light look (black ink logo on ivory), so colors are set explicitly. */
:root {
  --bg: #FBF8F3;        /* ivory page */
  --band: #F3EDE3;      /* linen band */
  --ink: #1E1A18;       /* text, buttons, black banner */
  --muted: #4A4038;     /* body copy */
  --soft: #6E6253;      /* captions */
  --line: #E8E0D4;      /* hairlines */
  --accent: #A8322A;    /* coral, used sparingly */
  --white: #FFFFFF;
  --display: 'Cormorant Garamond', 'Cormorant', Garamond, 'Times New Roman', serif;
  --body: 'Jost', 'Futura', 'Century Gothic', 'Avenir Next', system-ui, sans-serif;
  color-scheme: light;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--body); font-weight: 300; font-size: 17px; line-height: 1.6;
}
img { max-width: 100%; display: block; }
a { color: var(--ink); }
a:hover { color: var(--accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
h1, h2, h3 { font-family: var(--display); font-weight: 400; line-height: 1.1; text-wrap: balance; margin: 0; }

.wrap {
  max-width: 1240px; margin: 0 auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}
.label {
  font-size: 13px; letter-spacing: 0.2em; text-transform: uppercase; font-weight: 400;
}
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; background: var(--white); padding: 8px 12px; z-index: 20; }

/* Banner + masthead */
.banner { background: var(--ink); color: var(--bg); text-align: center; padding-block: 10px; }
.banner p { margin: 0; }
.masthead { border-bottom: 1px solid var(--line); background: var(--bg); }
.masthead .wrap {
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 24px; padding-block: 18px;
}
.nav-group { display: flex; flex-wrap: wrap; gap: 8px 22px; list-style: none; margin: 0; padding: 0; }
.nav-group.right { justify-content: flex-end; }
.nav-group a { text-decoration: none; padding-block: 10px; display: inline-block; white-space: nowrap; letter-spacing: 0.14em; }
.nav-group a[aria-current="page"] { color: var(--accent); }
.brand img { height: 64px; width: auto; }
@media (max-width: 1180px) {
  .masthead .wrap { grid-template-columns: 1fr; justify-items: center; gap: 6px; padding-block: 14px 8px; }
  .brand { order: -1; }
  .nav-group, .nav-group.right { justify-content: center; gap: 0 20px; }
  .nav-group .label { font-size: 12px; letter-spacing: 0.14em; }
}

/* Home hero */
.hero .wrap { display: flex; flex-wrap: wrap; gap: 48px; align-items: center; padding-block: 64px 88px; }
.hero-text { flex: 1 1 420px; min-width: 0; display: flex; flex-direction: column; gap: 26px; align-items: flex-start; }
.hero-logo { width: 300px; max-width: 72%; height: auto; }
.hero h1 { font-size: clamp(34px, 4.2vw, 54px); line-height: 1.08; max-width: 14em; }
.hero p { margin: 0; font-size: 19px; color: var(--muted); max-width: 30em; }
.hero-photo { flex: 1 1 400px; min-width: 0; display: flex; justify-content: center; }
.hero-photo img { width: 100%; max-width: 480px; aspect-ratio: 3 / 4; object-fit: cover; }

/* Section heads */
.section { padding-block: 96px; }
.section.tight { padding-block: 64px; }
.band { background: var(--band); }
.section-head { display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; margin-bottom: 48px; }
.section-head img { width: 44px; height: auto; }
.section-head h2 { font-size: clamp(36px, 4.4vw, 52px); }
.section-head p { margin: 0; color: var(--muted); max-width: 36em; }

/* Category tiles on home */
.tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 28px; }
@media (max-width: 1000px) { .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .tiles { gap: 28px 14px; } .tile h3 { font-size: 21px; } }
.tile { text-decoration: none; display: flex; flex-direction: column; gap: 14px; }
.tile img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; transition: transform .5s ease; }
.tile .frame { overflow: hidden; }
.tile:hover img { transform: scale(1.03); }
.tile h3 { font-size: 26px; }
.tile .label { color: var(--accent); }

/* Split blocks (about) */
.split { display: flex; flex-wrap: wrap; gap: 56px; align-items: center; }
.split > .photo { flex: 1 1 340px; max-width: 440px; min-width: 0; }
.split > .photo img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.split > .text { flex: 1 1 420px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.split .eyebrow { color: var(--accent); margin: 0; }
.split h2 { font-size: clamp(34px, 4vw, 46px); }
.prose p { margin: 0 0 1em; color: var(--muted); font-size: 18px; line-height: 1.75; max-width: 38em; }
.prose p:last-child { margin-bottom: 0; }

/* Page intro (inner pages) */
.page-intro { padding-block: 72px 40px; text-align: center; }
.page-intro .wrap { display: flex; flex-direction: column; align-items: center; gap: 16px; }
.page-intro img.mark { width: 48px; height: auto; }
.page-intro h1 { font-size: clamp(42px, 5.6vw, 68px); }
.page-intro p { margin: 0; color: var(--muted); font-size: 19px; max-width: 34em; }
.subnav { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 12px; list-style: none; padding: 0; }
.subnav a { display: inline-block; text-decoration: none; border: 1px solid var(--ink); padding: 10px 22px; }
.subnav a:hover { background: var(--ink); color: var(--bg); }

/* Galleries */
.gallery-section { padding-block: 40px 72px; scroll-margin-top: 16px; }
.gallery-section + .gallery-section { border-top: 1px solid var(--line); padding-top: 64px; }
.gallery-section h2 { font-size: 40px; margin-bottom: 32px; }
.gallery { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 40px 28px; list-style: none; margin: 0; padding: 0; }
@media (max-width: 1100px) { .gallery { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 760px) { .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px 16px; } }
.piece { display: flex; flex-direction: column; gap: 12px; }
.piece button {
  all: unset; cursor: zoom-in; display: block; background: var(--band); overflow: hidden;
}
.piece button:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.piece img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; transition: transform .5s ease; }
.piece img.fit { object-fit: contain; }
.piece button:hover img { transform: scale(1.03); }
.piece h3 { font-size: 22px; line-height: 1.2; }
.piece p { margin: 0; font-size: 15px; color: var(--soft); }

/* Inquiry call-to-action */
.inquire { text-align: center; }
.inquire .wrap { display: flex; flex-direction: column; align-items: center; gap: 18px; padding-block: 72px; }
.inquire h2 { font-size: clamp(32px, 4vw, 44px); }
.inquire p { margin: 0; color: var(--muted); max-width: 34em; }
.btn {
  display: inline-block; background: var(--ink); color: var(--bg); text-decoration: none; border: 0;
  padding: 16px 34px; font: inherit; font-size: 13px; letter-spacing: 0.2em; text-transform: uppercase; font-weight: 400; cursor: pointer;
}
.btn:hover { background: var(--accent); color: var(--white); }
.text-link { font-size: 13px; letter-spacing: 0.2em; text-transform: uppercase; font-weight: 400; }

/* Contact form */
.contact .wrap { max-width: 900px; }
.form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin-top: 40px; }
.form .full { grid-column: 1 / -1; }
@media (max-width: 600px) { .form { grid-template-columns: minmax(0, 1fr); } }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: 13px; letter-spacing: 0.14em; text-transform: uppercase; font-weight: 400; }
.field input, .field textarea {
  font: inherit; font-weight: 300; font-size: 17px; color: var(--ink); background: var(--white);
  border: 1px solid #B9AE9F; padding: 14px 16px; width: 100%;
}
.field textarea { min-height: 160px; resize: vertical; }
.field input:focus, .field textarea:focus { outline: 2px solid var(--accent); outline-offset: 0; border-color: var(--accent); }
.form-note { grid-column: 1 / -1; margin: 0; padding: 14px 16px; background: var(--band); border-left: 3px solid var(--accent); }

/* Footer */
.site-footer { border-top: 1px solid var(--line); }
.site-footer .wrap { display: flex; flex-direction: column; align-items: center; gap: 24px; padding-block: 56px 40px; text-align: center; }
.site-footer img { height: 72px; width: auto; }
.footer-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 32px; list-style: none; margin: 0; padding: 0; }
.footer-links a { display: inline-block; padding-block: 8px; }
.fine { margin: 0; font-size: 14px; color: var(--soft); }

/* Lightbox */
dialog.lightbox {
  border: 0; padding: 0; background: transparent; max-width: min(92vw, 900px); max-height: 92vh; color: var(--bg);
}
dialog.lightbox::backdrop { background: rgba(20, 17, 15, 0.86); }
dialog.lightbox figure { margin: 0; display: flex; flex-direction: column; align-items: center; gap: 12px; }
dialog.lightbox img { max-height: 80vh; width: auto; max-width: 100%; }
dialog.lightbox figcaption { font-family: var(--display); font-size: 24px; text-align: center; }
dialog.lightbox .close {
  position: fixed; top: max(12px, env(safe-area-inset-top, 0px)); right: max(12px, env(safe-area-inset-right, 0px));
  width: 48px; height: 48px; border: 1px solid var(--bg); background: transparent; color: var(--bg); font: inherit; font-size: 26px; cursor: pointer;
}
.gallery-empty { margin: 0; color: var(--soft); font-style: italic; }
