/* Kiera's Craft Corner
   Lavender + purple boho theme. Colors live in :root so they are easy to tweak. */

:root {
  --cream: #fbf7f1;
  --cream-deep: #f3ece2;
  --lavender: #dcd0f2;        /* matches the logo circle */
  --lavender-soft: #ede6f8;
  --lavender-line: #c7b6e8;
  --purple: #6d4fa3;
  --purple-deep: #452d6e;
  --ink: #2b2236;
  --ink-soft: #5d5368;
  --white: #fff;

  --font-display: "Fraunces", Georgia, serif;
  --font-script: "Sacramento", cursive;
  --font-body: "Nunito", system-ui, -apple-system, "Segoe UI", sans-serif;

  --radius: 18px;
  --shadow: 0 10px 30px -12px rgba(69, 45, 110, .28);
  --max: 1120px;
  color-scheme: light;
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background-color: var(--cream);
  /* soft cabana stripes, like the inspiration sample, in lavender */
  background-image: repeating-linear-gradient(
    90deg,
    var(--cream) 0 34px,
    var(--lavender-soft) 34px 68px
  );
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--purple); }
a:hover { color: var(--purple-deep); }

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.15;
  color: var(--purple-deep);
  margin: 0 0 .5em;
  letter-spacing: -.01em;
}
h1 { font-size: clamp(2.3rem, 6vw, 3.6rem); }
h2 { font-size: clamp(1.9rem, 4.5vw, 2.6rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }

.script {
  font-family: var(--font-script);
  font-weight: 400;
  color: var(--purple);
  font-size: 1.6em;
  line-height: 1;
  letter-spacing: 0;
}

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

.skip-link {
  position: absolute; left: -999px; top: 8px;
  background: var(--purple-deep); color: var(--white);
  padding: 8px 14px; border-radius: 8px; z-index: 100;
}
.skip-link:focus { left: 8px; }

:focus-visible { outline: 3px solid var(--purple); outline-offset: 3px; border-radius: 6px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  font-family: var(--font-body); font-weight: 800; font-size: 1rem;
  padding: .8em 1.5em; border-radius: 999px; border: 2px solid var(--purple-deep);
  text-decoration: none; cursor: pointer; transition: transform .15s, background .15s, color .15s;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--purple-deep); color: var(--white); }
.btn-primary:hover { background: var(--purple); border-color: var(--purple); color: var(--white); }
.btn-ghost { background: transparent; color: var(--purple-deep); }
.btn-ghost:hover { background: var(--lavender); color: var(--purple-deep); }
.btn svg { width: 1.15em; height: 1.15em; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(251, 247, 241, .94);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--lavender-line);
}
.nav { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 72px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--purple-deep); }
.brand img { width: 52px; height: 52px; border-radius: 50%; border: 2px solid var(--lavender-line); }
.brand-name { font-family: var(--font-display); font-weight: 600; font-size: 1.2rem; line-height: 1.1; }
.brand-name small { display: block; font-family: var(--font-script); font-size: 1.25rem; color: var(--purple); font-weight: 400; }

.nav-links { list-style: none; display: flex; align-items: center; gap: 6px; margin: 0; padding: 0; }
.nav-links a:not(.btn) {
  display: block; padding: 8px 14px; border-radius: 999px;
  text-decoration: none; color: var(--ink); font-weight: 700;
}
.nav-links a:not(.btn):hover, .nav-links a[aria-current="page"]:not(.btn) { background: var(--lavender); color: var(--purple-deep); }
.nav-links .btn { padding: .55em 1.2em; margin-left: 6px; }

.nav-toggle {
  display: none; background: none; border: 2px solid var(--purple-deep); color: var(--purple-deep);
  width: 44px; height: 44px; border-radius: 12px; padding: 8px; cursor: pointer;
}

@media (max-width: 760px) {
  .nav-toggle { display: block; }
  .nav-links {
    display: none; position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 4px;
    background: var(--cream); padding: 12px 20px 20px; border-bottom: 1px solid var(--lavender-line);
    box-shadow: var(--shadow);
  }
  .nav-links.open { display: flex; }
  .nav-links .btn { margin: 6px 0 0; }
  .brand-name { font-size: 1.05rem; }
}

/* ---------- Scalloped edges ---------- */
/* Add .scallop-bottom or .scallop-top to any section with a --band color. */
.band { position: relative; background: var(--band, var(--lavender)); }
.scallop-bottom::after, .scallop-top::before {
  content: ""; position: absolute; left: 0; right: 0; height: 18px; pointer-events: none;
  background-repeat: repeat-x; background-size: 36px 18px;
}
.scallop-bottom::after {
  top: 100%;
  background-image: radial-gradient(circle at 18px 0, var(--band, var(--lavender)) 17px, transparent 18px);
}
.scallop-top::before {
  bottom: 100%;
  background-image: radial-gradient(circle at 18px 18px, var(--band, var(--lavender)) 17px, transparent 18px);
}

/* ---------- Hero ---------- */
.hero { --band: var(--cream); padding: 56px 0 64px; border-bottom: 0; }
.hero-inner { display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; }
.hero .script { display: block; margin-bottom: .1em; }
.hero h1 { margin-bottom: .35em; }
.lead { font-size: 1.15rem; color: var(--ink-soft); max-width: 34em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }

.hero-art { position: relative; justify-self: center; width: min(420px, 100%); }
.arch {
  background: var(--lavender);
  border-radius: 999px 999px var(--radius) var(--radius);
  padding: 28px; box-shadow: var(--shadow);
  border: 2px solid var(--white); outline: 2px solid var(--lavender-line); outline-offset: 6px;
}
.arch img { border-radius: 50%; background: var(--white); }
.sparkle { position: absolute; color: var(--purple); width: 30px; height: 30px; }
.sparkle.s1 { top: -6px; left: -10px; }
.sparkle.s2 { bottom: 26px; right: -16px; width: 22px; height: 22px; }

@media (max-width: 820px) {
  .hero { padding: 36px 0 48px; text-align: center; }
  .hero-inner { grid-template-columns: 1fr; }
  .hero-art { order: -1; width: min(280px, 80%); }
  .lead { margin-inline: auto; }
  .hero-actions { justify-content: center; }
}

/* ---------- Sections ---------- */
.section { padding: 72px 0; }
.section-head { text-align: center; max-width: 640px; margin: 0 auto 40px; }
.section-head .script { display: block; font-size: 2rem; }
.section-head p { color: var(--ink-soft); }

.band-lavender { --band: var(--lavender); }
.band-cream { --band: var(--cream); }
.band-purple { --band: var(--purple-deep); color: var(--lavender-soft); }
.band-purple h2, .band-purple h3 { color: var(--white); }
.band-purple .script { color: var(--lavender); }

/* ---------- Collection badges ---------- */
.badges { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 28px 40px; }
.badge a {
  display: flex; flex-direction: column; align-items: center; gap: 10px;
  text-decoration: none; color: var(--purple-deep); text-align: center;
}
.badge-circle {
  width: 170px; height: 170px; border-radius: 50%;
  background: var(--cream); display: grid; place-items: center;
  border: 2px dashed var(--lavender-line);
  box-shadow: 0 0 0 8px var(--cream), 0 0 0 10px var(--purple), var(--shadow);
  transition: transform .2s;
}
.badge-circle svg { width: 84px; height: 84px; color: var(--purple-deep); }
.badge a:hover .badge-circle { transform: translateY(-4px) rotate(-3deg); }
.badge-label { font-family: var(--font-display); font-weight: 600; font-size: 1.2rem; margin-top: 10px; }
@media (max-width: 520px) {
  .badges { gap: 24px 22px; }
  .badge-circle { width: 124px; height: 124px; box-shadow: 0 0 0 6px var(--cream), 0 0 0 8px var(--purple), var(--shadow); }
  .badge-circle svg { width: 60px; height: 60px; }
  .badge-label { font-size: 1.05rem; }
}

/* ---------- Product cards ---------- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 24px; }
.card {
  background: var(--white); border-radius: var(--radius); overflow: hidden;
  box-shadow: var(--shadow); border: 1px solid var(--lavender-line);
  display: flex; flex-direction: column; text-align: left;
  font: inherit; color: inherit; padding: 0; cursor: pointer; width: 100%;
  transition: transform .2s;
}
.card:hover { transform: translateY(-4px); }
.card-img { aspect-ratio: 1 / 1; background: var(--lavender-soft); position: relative; }
.card-img img { width: 100%; height: 100%; object-fit: cover; }
.card-body { padding: 14px 16px 18px; display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.card-name { font-family: var(--font-display); font-weight: 600; font-size: 1.08rem; color: var(--purple-deep); }
.card-cat { display: block; font-size: .82rem; color: var(--ink-soft); font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.price { font-weight: 800; color: var(--purple); white-space: nowrap; }

.placeholder {
  width: 100%; height: 100%; display: grid; place-items: center; align-content: center; gap: 6px;
  color: var(--purple); text-align: center;
  background: repeating-linear-gradient(135deg, var(--lavender-soft) 0 14px, var(--cream) 14px 28px);
}
.placeholder svg { width: 72px; height: 72px; opacity: .8; }
.placeholder span { font-family: var(--font-script); font-size: 1.9rem; line-height: 1; }

/* ---------- Shop filters ---------- */
.filters { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin: 0 0 36px; padding: 0; list-style: none; }
.filters button {
  font: inherit; font-weight: 800; cursor: pointer;
  padding: .55em 1.2em; border-radius: 999px;
  border: 2px solid var(--purple-deep); background: var(--cream); color: var(--purple-deep);
}
.filters button[aria-pressed="true"] { background: var(--purple-deep); color: var(--white); }
.empty { text-align: center; color: var(--ink-soft); }

/* ---------- Item dialog ---------- */
.item-dialog {
  border: none; border-radius: var(--radius); padding: 0; max-width: min(760px, calc(100vw - 32px));
  width: 100%; box-shadow: 0 30px 80px -20px rgba(43, 34, 54, .5); background: var(--cream);
}
.item-dialog::backdrop { background: rgba(43, 34, 54, .55); }
.dialog-inner { display: grid; grid-template-columns: 1fr 1fr; }
.dialog-img { background: var(--lavender-soft); aspect-ratio: 1/1; }
.dialog-img img { width: 100%; height: 100%; object-fit: cover; }
.dialog-body { padding: 28px; display: flex; flex-direction: column; gap: 8px; }
.dialog-body .price { font-size: 1.35rem; }
.dialog-body .actions { margin-top: auto; display: flex; flex-wrap: wrap; gap: 10px; }
.dialog-close {
  position: absolute; top: 10px; right: 10px; width: 40px; height: 40px; border-radius: 50%;
  border: none; background: var(--white); color: var(--purple-deep); font-size: 1.5rem; cursor: pointer;
  box-shadow: var(--shadow);
}
@media (max-width: 640px) {
  .dialog-inner { grid-template-columns: 1fr; }
  .dialog-body { padding: 20px; }
}

/* ---------- Two-column feature ---------- */
.split { display: grid; grid-template-columns: .9fr 1.1fr; gap: 48px; align-items: center; }
.split .arch { max-width: 360px; justify-self: center; }
@media (max-width: 820px) {
  .split { grid-template-columns: 1fr; text-align: center; gap: 28px; }
}

.craft-list { list-style: none; padding: 0; margin: 0 0 1.4em; display: grid; gap: 10px; }
.craft-list li { display: flex; gap: 10px; align-items: flex-start; }
.craft-list svg { flex: none; width: 22px; height: 22px; color: var(--purple); margin-top: 3px; }
@media (max-width: 820px) { .craft-list { justify-items: center; } }

/* ---------- Page hero (inner pages) ---------- */
.page-hero { padding: 48px 0 40px; text-align: center; }
.page-hero .script { display: block; font-size: 2.2rem; }
.page-hero p { color: var(--ink-soft); max-width: 36em; margin: 0 auto; }

/* ---------- Forms ---------- */
.form-card {
  background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow);
  border: 1px solid var(--lavender-line); padding: 32px; max-width: 640px; margin: 0 auto;
}
.form { display: grid; gap: 18px; }
.field { display: grid; gap: 6px; }
.field label { font-weight: 800; color: var(--purple-deep); }
.field .hint { font-weight: 400; color: var(--ink-soft); font-size: .9rem; }
.field input, .field textarea, .field select {
  font: inherit; color: var(--ink); background: var(--cream);
  border: 2px solid var(--lavender-line); border-radius: 12px; padding: 12px 14px; width: 100%;
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--purple); background: var(--white); }
.field textarea { min-height: 150px; resize: vertical; }
.field-error { color: #9b1c4a; font-size: .9rem; font-weight: 700; display: none; }
.field.invalid .field-error { display: block; }
.field.invalid input, .field.invalid textarea { border-color: #9b1c4a; }
.hidden-field { position: absolute; left: -9999px; }
@media (max-width: 520px) { .form-card { padding: 22px 18px; } }

.contact-alt { text-align: center; margin-top: 32px; color: var(--ink-soft); }

/* ---------- Footer ---------- */
.site-footer { --band: var(--purple-deep); color: var(--lavender-soft); padding: 56px 0 28px; margin-top: 18px; }
.footer-inner { display: grid; grid-template-columns: auto 1fr auto; gap: 32px; align-items: center; }
.footer-logo { width: 96px; height: 96px; border-radius: 50%; border: 3px solid var(--lavender); }
.footer-tag { font-family: var(--font-script); font-size: 2rem; color: var(--lavender); line-height: 1.1; margin: 0; }
.footer-sub { margin: 4px 0 0; }
.footer-links { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 18px; justify-content: flex-end; }
.footer-links a { color: var(--white); text-decoration: none; font-weight: 700; }
.footer-links a:hover { color: var(--lavender); text-decoration: underline; }
.social { display: flex; gap: 10px; justify-content: flex-end; margin-top: 14px; }
.social a {
  display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 999px;
  background: var(--lavender); color: var(--purple-deep); text-decoration: none; font-weight: 800;
}
.social a:hover { background: var(--white); color: var(--purple-deep); }
.social svg { width: 20px; height: 20px; }
.copyright { text-align: center; font-size: .9rem; opacity: .8; margin: 36px 0 0; }
@media (max-width: 760px) {
  .footer-inner { grid-template-columns: 1fr; justify-items: center; text-align: center; }
  .footer-links, .social { justify-content: center; }
}

/* JS sets [hidden] on optional links (e.g. Etsy) until a URL is filled in */
[hidden] { display: none !important; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}
