/* =========================================================
   Jubilation Paper Goods - shared styles
   Colors are pulled from the logo. Change them here and the
   whole site updates.
   ========================================================= */
:root {
  --stamp-pink: #F7C3CA;   /* stamp border */
  --rose: #E8909A;         /* SINCE 2026 banner */
  --teal: #3F8A8F;         /* notebook cover */
  --mint: #C4E7E1;         /* pencil */
  --peach: #F6A980;        /* notebook ribbon */
  --paper: #FFFBF3;        /* stamp paper */
  --ink: #000000;          /* outlines */
  --ink-soft: #3d3d3d;

  --display: "Grandstander", "Comic Sans MS", "Trebuchet MS", sans-serif;
  --body: "Nunito", "Segoe UI", Helvetica, Arial, sans-serif;
  --line: 3px solid var(--ink);
  --perf: 8px;             /* size of stamp perforations */
}

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

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
}

img { max-width: 100%; display: block; }
a { color: var(--teal); text-underline-offset: 3px; }
a:hover { color: var(--ink); }
:focus-visible { outline: 3px solid var(--teal); outline-offset: 3px; border-radius: 4px; }

h1, h2, h3 { font-family: var(--display); font-weight: 700; line-height: 1.15; margin: 0 0 .5em; }
h1 { font-size: clamp(2.2rem, 5vw, 3.4rem); }
h2 { font-size: clamp(1.7rem, 3.5vw, 2.3rem); }
h3 { font-size: 1.35rem; }

.wrap { width: min(1120px, 100% - 2.5rem); margin-inline: auto; }
.narrow { width: min(720px, 100% - 2.5rem); margin-inline: auto; }

.skip { position: absolute; left: -999px; }
.skip:focus { left: 1rem; top: 1rem; background: var(--paper); padding: .5rem 1rem; z-index: 10; }

/* ---------- Header ---------- */
.site-header { border-bottom: var(--line); background: var(--stamp-pink); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-block: .6rem; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: .7rem; text-decoration: none; color: var(--ink); }
.brand img { width: 64px; height: 64px; }
.brand span { font-family: var(--display); font-weight: 700; font-size: 1.35rem; line-height: 1.05; }
.brand small { display: block; font-size: .95rem; font-weight: 600; }
.nav { display: flex; gap: .35rem; flex-wrap: wrap; }
.nav a {
  font-family: var(--display); font-weight: 600; font-size: 1.05rem;
  color: var(--ink); text-decoration: none; padding: .35rem .9rem;
  border: 2px solid transparent; border-radius: 999px;
}
.nav a:hover { border-color: var(--ink); background: var(--paper); }
.nav a[aria-current="page"] { background: var(--ink); color: var(--paper); }

/* ---------- Hero (home) ---------- */
.hero { padding-block: clamp(2.5rem, 6vw, 4.5rem); border-bottom: var(--line); }
.hero .wrap { display: grid; grid-template-columns: 1.2fr .8fr; gap: 2.5rem; align-items: center; }
.hero p.lede { font-size: 1.2rem; max-width: 34ch; color: var(--ink-soft); margin: 0 0 1.5rem; }
.hero-logo { width: min(360px, 100%); justify-self: center; transform: rotate(4deg); }
@media (prefers-reduced-motion: no-preference) {
  .hero-logo { animation: land .7s cubic-bezier(.3,1.4,.5,1) both; }
  @keyframes land { from { transform: rotate(-8deg) scale(.85); opacity: 0; } to { transform: rotate(4deg) scale(1); opacity: 1; } }
}
@media (max-width: 760px) {
  .hero .wrap { grid-template-columns: 1fr; }
  .hero-logo { width: 220px; grid-row: 1; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; font-family: var(--display); font-weight: 700; font-size: 1.1rem;
  padding: .6rem 1.4rem; border: var(--line); border-radius: 999px;
  background: var(--rose); color: var(--ink); text-decoration: none; cursor: pointer;
  box-shadow: 3px 3px 0 var(--ink);
}
.btn:hover { background: var(--peach); color: var(--ink); }
.btn:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--ink); }
.btn.is-off { background: #e9e4dc; color: var(--ink-soft); box-shadow: none; cursor: default; }

/* ---------- Shop ---------- */
.shop { padding-block: 3rem 4rem; }
.shop-head { display: flex; justify-content: space-between; align-items: end; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.5rem; }
.shop-head h2 { margin: 0; }
.filters { display: flex; gap: .5rem; flex-wrap: wrap; }
.filters button {
  font: 600 1rem var(--body); padding: .4rem 1rem; border: 2px solid var(--ink);
  border-radius: 999px; background: var(--paper); color: var(--ink); cursor: pointer;
}
.filters button[aria-pressed="true"] { background: var(--teal); color: #fff; }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 2rem 1.75rem; }

/* The postage stamp card: pink perforated border, cream inner panel */
.stamp {
  padding: calc(var(--perf) * 2.2);
  background: var(--stamp-pink);
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    radial-gradient(var(--perf), #0000 97%, #000) calc(-1 * var(--perf)) calc(-1 * var(--perf)) / calc(var(--perf) * 2.6) calc(var(--perf) * 2.6) round;
          mask:
    linear-gradient(#000 0 0) content-box,
    radial-gradient(var(--perf), #0000 97%, #000) calc(-1 * var(--perf)) calc(-1 * var(--perf)) / calc(var(--perf) * 2.6) calc(var(--perf) * 2.6) round;
}
.grid .stamp:nth-child(3n+2) { background: var(--mint); }
.grid .stamp:nth-child(3n+3) { background: #F9D5B8; }

.card { background: var(--paper); border: var(--line); height: 100%; display: flex; flex-direction: column; }
.card-img { aspect-ratio: 1 / 1; border-bottom: var(--line); background: #fff; overflow: hidden; }
.card-img img { width: 100%; height: 100%; object-fit: cover; }
.card-img.empty { display: grid; place-items: center; text-align: center; color: var(--ink-soft); font-weight: 600; background: repeating-linear-gradient(-45deg, #fff 0 14px, #fdf3f4 14px 28px); }
.card-img.empty img { width: 42%; height: auto; opacity: .55; margin: 0 auto .5rem; }
.card-body { padding: 1rem 1.1rem 1.2rem; display: flex; flex-direction: column; gap: .5rem; flex: 1; }
.card-cat { font-size: .9rem; font-weight: 700; color: var(--teal); margin: 0; }
.card h3 { margin: 0; }
.card-desc { margin: 0; color: var(--ink-soft); flex: 1; }
.card-foot { display: flex; align-items: center; justify-content: space-between; gap: .75rem; margin-top: .5rem; }
.price { font-family: var(--display); font-weight: 700; font-size: 1.5rem; }
.empty-shop { padding: 2rem; border: 2px dashed var(--ink); text-align: center; }

.note { font-size: .95rem; color: var(--ink-soft); margin-top: 2rem; }

/* ---------- Content pages ---------- */
.page-head { background: var(--stamp-pink); border-bottom: var(--line); padding-block: 2.5rem 2rem; }
.page-head p { margin: 0; font-size: 1.15rem; max-width: 55ch; }
.content { padding-block: 2.5rem 4rem; }
.content h2 { margin-top: 2rem; font-size: 1.6rem; }
.content p, .content li { max-width: 65ch; }

/* ---------- Contact form ---------- */
.form { display: grid; gap: 1.1rem; margin-top: 1.5rem; }
.form label { font-weight: 700; display: grid; gap: .35rem; }
.form input, .form textarea, .form select {
  font: inherit; padding: .65rem .8rem; border: var(--line); border-radius: 10px; background: #fff; color: var(--ink);
}
.form textarea { min-height: 150px; resize: vertical; }
.form .hp { position: absolute; left: -9999px; }
.alert { padding: 1rem 1.2rem; border: var(--line); border-radius: 12px; margin-top: 1rem; font-weight: 600; }
.alert.ok { background: var(--mint); }
.alert.bad { background: var(--stamp-pink); }

/* ---------- Footer ---------- */
.site-footer { border-top: var(--line); background: var(--teal); color: #fff; padding-block: 2rem; }
.site-footer .wrap { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.site-footer a { color: #fff; }
.site-footer nav { display: flex; gap: 1.2rem; flex-wrap: wrap; }

/* ---------- Small phones ---------- */
@media (max-width: 480px) {
  .site-header .wrap { justify-content: center; }
  .brand img { width: 48px; height: 48px; }
  .nav { justify-content: center; gap: .15rem; }
  .nav a { padding: .3rem .65rem; font-size: 1rem; }
}
