:root {
  --bg: #faf9f5;
  --ink: #183d30;
  --accent: #214b38;
  --muted: #626c63;
  --line: #d9dcd1;
  --soft: #e6ecdf;
  --rust: #a9472d;
  --editorial-serif: "Yu Mincho", "Hiragino Mincho ProN", "Noto Serif CJK JP", serif;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
body { background: var(--bg); }
.header { background: rgba(250,249,245,.97); border-bottom: 1px solid var(--line); }
.header .nav {
  max-width: 1280px;
  min-height: 76px;
  gap: clamp(12px,1.6vw,24px);
  padding: 10px clamp(18px,3vw,42px);
}
.logo { display: inline-flex; align-items: center; min-height: 44px; }
.logo img { display: block; width: 150px; height: 35px; object-fit: contain; object-position: left center; }
.header .logo { flex: 0 0 auto; }
.footer-inner .logo img { width: 160px; height: 38px; }
.install-dialog .install-icon { display: block; width: 66px; height: 66px; border-radius: 15px; background: transparent; }
.header .desktop-nav { margin-right: auto; gap: 2px; }
.header .desktop-nav .navbtn {
  border-radius: 0;
  border-bottom: 2px solid transparent;
  background: transparent;
  padding: 10px clamp(6px, .8vw, 13px);
}
.header .desktop-nav .navbtn.active { border-bottom-color: var(--rust); color: var(--ink); }
.header .front-search {
  margin: 0;
  flex: 0 1 255px;
  padding: 0 3px 0 12px;
  gap: 0;
  background: #fff;
  border: 1px solid #cbd0c4;
  border-radius: 30px;
}
.header .front-search:focus-within { outline: 2px solid var(--accent); outline-offset: 2px; }
.header .front-search input {
  max-width: 100%;
  padding: 9px 0;
  font-size: 14px;
  outline: none;
  border: none;
}
.header .front-search button {
  display: grid;
  place-items: center;
  width: 43px;
  height: 43px;
  flex: 0 0 43px;
  border-radius: 50%;
  padding: 0;
  color: var(--ink);
  background: transparent;
}
.magnify, .search-drawing::before {
  display: block;
  position: relative;
  width: 15px;
  height: 15px;
  border: 2px solid currentColor;
  border-radius: 50%;
}
.magnify::after, .search-drawing::after {
  content: "";
  position: absolute;
  width: 8px;
  height: 2px;
  background: currentColor;
  transform: rotate(45deg);
  transform-origin: left;
}
.magnify::after { top: 11px; left: 11px; }
.header .install-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-height: 44px;
  border: none;
  background: transparent;
  padding: 0 3px;
}
.header .install-btn .install-word { font-size: 13px; }
.home-page, .subpage { max-width: 1280px; padding-inline: clamp(18px,3vw,42px); }
.home-page { padding-top: 23px; }
.content-section { margin-bottom: clamp(38px,5vw,73px); }
.home-page .section-head { margin-bottom: 19px; align-items: center; }
.home-page .section-head h2, .subpage .page-heading h1 {
  font-family: var(--editorial-serif);
  color: var(--ink);
  font-weight: 650;
  letter-spacing: -.045em;
}
.home-page .section-head h2 { font-size: clamp(24px,2.7vw,38px); }
.home-page .text-btn { color: var(--accent); }
.feature-spread { margin: 0 0 clamp(34px,4.8vw,68px); }
.feature-lead {
  display: grid;
  grid-template-columns: minmax(0, .85fr) minmax(0, 1.4fr);
  align-items: stretch;
  overflow: hidden;
  color: var(--ink);
  background: #ecebe0;
  border-radius: 3px;
}
.feature-lead picture {
  display: block;
  grid-column: 2;
  grid-row: 1;
  min-width: 0;
}
.feature-lead picture img {
  width: 100%;
  height: 100%;
  aspect-ratio: 1.6;
  min-height: clamp(320px,32vw,440px);
  max-height: 510px;
  object-fit: cover;
}
.feature-caption {
  grid-column: 1;
  grid-row: 1;
  align-self: center;
  padding: clamp(20px,3.7vw,54px);
}
#featureKind {
  margin: 0 0 15px;
  color: #884129;
  font-size: 13px;
  font-weight: 750;
  letter-spacing: .12em;
}
.feature-caption h1 {
  margin: 0;
  font: 650 clamp(31px,3.8vw,58px)/1.29 var(--editorial-serif);
  letter-spacing: -.065em;
  overflow-wrap: anywhere;
}
#featureSummary {
  max-width: 26em;
  margin: 15px 0 24px;
  font-size: 15px;
  line-height: 1.85;
}
.read-feature, .home-page .hero-btn {
  min-height: 46px;
  padding: 11px 22px;
  background: var(--ink);
  color: #fff;
  border-radius: 3px;
  font-weight: 700;
  font-size: 14px;
}
.read-feature:hover, .home-page .hero-btn:hover { background: #31614a; }
.feature-picker {
  display: grid;
  grid-template-columns: repeat(4,minmax(0,1fr));
  border-bottom: 1px solid var(--line);
}
.feature-picker button {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  position: relative;
  gap: 13px;
  padding: 13px 12px;
  min-height: 64px;
  color: var(--muted);
  text-align: left;
  font-size: 15px;
  font-weight: 650;
}
.feature-picker button[aria-pressed="true"] { color: var(--rust); }
.feature-picker button[aria-pressed="true"]::after {
  content: "";
  position: absolute;
  bottom: -1px;
  height: 3px;
  left: 0;
  right: 0;
  background: var(--rust);
}
.feature-picker button:hover { background: #efefe7; }
.feature-picker img { width: 54px; height: 39px; border-radius: 2px; object-fit: cover; }
.home-page .shelf-modes { margin-bottom: 20px; }
.home-page .shelf-modes button { min-height: 41px; padding-inline: 16px; border-radius: 30px; }
.category-grid { gap: clamp(10px,1.4vw,18px); }
.category-card { color: var(--ink); }
.category-card img { aspect-ratio: 1; border-radius: 50%; }
.budget-section { padding: 23px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.budget-collection { gap: 12px; }
.budget-collection button {
  min-height: 70px;
  justify-content: center;
  border: 1px solid #d3d8cc;
  border-radius: 3px;
  background: #f0f2e9;
}
.budget-collection button:nth-child(2) { background: #efeae0; }
.budget-collection button:nth-child(3) { background: #e7ece5; }
.budget-collection button:hover { border-color: var(--accent); }
.budget-collection button strong { font: 500 clamp(24px,3vw,42px)/1.1 Georgia,serif; }
.budget-collection button strong small { font-family: inherit; font-size: 14px; }
.gift-banner {
  min-height: 260px;
  border-radius: 3px;
  background: var(--ink);
  color: white;
  grid-template-columns: .9fr 1.1fr;
}
.gift-banner>div { padding: clamp(20px,3.6vw,52px); }
.gift-banner h2 { font-size: clamp(26px,3.2vw,43px); line-height: 1.35; margin: 0; }
.gift-banner p { color: #e0e7d9; max-width: 26em; }
.home-page .gift-banner .hero-btn { background: #f8f6e9; color: var(--ink); }
.gift-banner img { min-height: 100%; }
#gift .page-heading {
  padding: clamp(20px,3vw,44px);
  position: relative;
  padding-right: 43%;
  background: #ece9dc;
  min-height: 150px;
  margin-bottom: 20px;
}
#gift .page-heading::after {
  content: "";
  position: absolute;
  inset: 0 0 0 60%;
  background: url("images/gift-wrap.webp") center / cover;
}
#gift .page-heading p { margin-bottom: 0; }
.footer-inner { max-width: 1280px; }
.front-search input:focus-visible { outline: none; }
@media (min-width:701px) and (max-width:960px) {
  .header .nav { gap: 10px; }
  .header .front-search { flex: 1 1 145px; }
  .header .install-word { display: none; }
  .header .install-btn { width: 44px; }
  .header .desktop-nav .navbtn { padding-inline: 6px; }
  .feature-picker button { gap: 7px; font-size: 14px; }
}
@media (max-width:700px) {
  .header .nav { min-height: 59px; padding: 6px 15px; gap: 12px; }
  .header .logo img { width: clamp(104px, 32vw, 138px); height: 32px; }
  .header .front-search { flex: 1 1 auto; min-width: 0; }
  .header .front-search input { font-size: 16px; }
  .header .install-word { display: none; }
  .header .install-btn { flex: 0 0 44px; width: 44px; background: #eceee5; border-radius: 50%; }
  .header .install-btn span:first-child { font-size: 23px; }
  .home-page, .subpage { padding-inline: 15px; }
  .home-page { padding-top: 12px; }
  .feature-lead { display: flex; flex-direction: column; }
  .feature-lead picture img {
    height: auto;
    min-height: 0;
    max-height: 290px;
    aspect-ratio: 1.68;
    object-position: center 52%;
  }
  .feature-caption {
    display: grid;
    grid-template-columns: minmax(0,1fr) auto;
    gap: 0 6px;
    padding: 14px 16px 16px;
    align-items: center;
    align-self: stretch;
  }
  #featureKind { grid-column: 1/-1; font-size: 12px; margin: 0 0 4px; }
  .feature-caption h1 { grid-column: 1/-1; font-size: clamp(24px,6.5vw,34px); line-height: 1.3; }
  .feature-caption h1 br { display: none; }
  #featureSummary { font-size: 13px; line-height: 1.65; margin: 8px 0 0; }
  .read-feature { min-height: 44px; font-size: 12px; padding: 9px 12px; margin-top: 7px; }
  .feature-picker { column-gap: 3px; }
  .feature-picker button { justify-content: center; min-height: 47px; font-size: 12px; white-space: nowrap; padding: 6px 1px; gap: 0; }
  .feature-picker img { display: none; }
  .feature-spread { margin-bottom: 26px; }
  .home-page .section-head { margin-bottom: 12px; }
  .home-page .section-head h2 { font-size: 25px; }
  .home-page .shelf-modes { margin-bottom: 13px; }
  .home-page .shelf-modes button { flex-shrink: 0; font-size: 12px; padding: 7px 10px; min-height: 40px; }
  .content-section { margin-bottom: 35px; }
  .category-grid { gap: 13px; }
  .category-card { flex-basis: 73px; }
  .budget-section { padding: 17px 0; }
  .budget-collection { gap: 6px; }
  .budget-collection button { min-height: 63px; padding: 11px 8px; }
  .budget-collection button strong { font-size: clamp(23px,6vw,31px); }
  .budget-collection button strong small { font-size: 11px; margin-left: 0; }
  .gift-banner { grid-template-columns: 1fr .93fr; min-height: 211px; }
  .gift-banner>div { padding: 18px 14px; }
  .gift-banner h2 { font-size: 23px; }
  .gift-banner p { font-size: 12px; }
  .home-page .gift-banner .hero-btn { font-size: 12px; padding: 8px 12px; }
  #gift .page-heading { padding: 20px 38% 20px 14px; min-height: 105px; }
  #gift .page-heading::after { left: 65%; }
  #gift .page-heading h1 { font-size: 26px; }
  .bottom-nav { background: #faf9f5f7; padding-top: 3px; }
  .bottom-nav .navbtn { position: relative; gap: 3px; min-height: 48px; font-size: 11px; border-radius: 6px; color: #67716b; }
  .bottom-nav .navbtn.active { color: var(--ink); background: #e9ede2; }
  .bottom-nav .navbtn i { position: absolute; top: 1px; left: calc(50% + 5px); background: var(--rust); color: white; border-radius: 8px; min-width: 14px; padding-inline: 2px; font: 700 10px/15px Arial,sans-serif; }
  .nav-drawing { position: relative; display: block; width: 22px; height: 22px; }
  .nav-drawing::before, .nav-drawing::after { content: ""; position: absolute; }
  .home-drawing::before { width: 13px; height: 13px; top: 2px; left: 4px; border-top: 1.9px solid; border-left: 1.9px solid; transform: rotate(45deg); }
  .home-drawing::after { width: 12px; height: 9px; top: 10px; left: 5px; border: 1.9px solid; border-top: none; }
  .search-drawing::before { left: 1px; top: 1px; }
  .search-drawing::after { left: 14px; top: 15px; }
  .save-drawing::before { inset: 1px 4px 1px; background: currentColor; clip-path: polygon(0 0,100% 0,100% 100%,50% 76%,0 100%,0 0,14% 11%,14% 82%,50% 63%,86% 82%,86% 11%,14% 11%); }
  .compare-drawing::before { width: 6px; height: 17px; left: 3px; top: 2px; border: 1.8px solid; }
  .compare-drawing::after { width: 6px; height: 11px; left: 13px; top: 8px; border: 1.8px solid; }
  .gift-drawing::before { left: 2px; top: 7px; width: 18px; height: 13px; border: 1.8px solid; background: linear-gradient(90deg,transparent 45%,currentColor 45% 55%,transparent 55%); }
  .gift-drawing::after { left: 5px; top: 2px; width: 11px; height: 4px; border: 1.8px solid; border-radius: 5px 5px 1px 1px; }
}
@media (max-width:355px) {
  .feature-caption { grid-template-columns: 1fr; }
  .read-feature { justify-self: start; }
  .header .nav { gap: 6px; }
}
