@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700;800&family=Manrope:wght@400;500;600;700;800&display=swap');

/* STORMHOUND shop — matches the main page. Replaces static/css/shop.css. */
:root {
  --navy: #08253b;
  --blue: #14537d;
  --muted: #60768a;
  --ice: #eaf4fa;
  --line: #e0e9ef;
  --ink: var(--navy);
  --paper: #f4f8fb;
  --green: var(--ice); /* Compatibility with existing templates. */
  --accent: #4b84a7;
  --danger: #a63d2d;
}

* { box-sizing: border-box; }
html { scroll-padding-top: 130px; }
body {
  margin: 0;
  color: var(--navy);
  background: linear-gradient(180deg, #eaf4fa 0, #f4f8fb 420px, #fff 1100px);
  font: 16px/1.6 'DM Sans', system-ui, -apple-system, sans-serif;
  min-height: 100vh;
}
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
button, .button, input, textarea, select, a { -webkit-tap-highlight-color: transparent; }
button, .button { transition: background .18s, border-color .18s, box-shadow .18s; }
a:focus-visible, button:focus-visible, summary:focus-visible {
  outline: 3px solid #1b80b9;
  outline-offset: 4px;
}
button, .button {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  min-height: 46px;
  padding: 12px 20px;
  border: 1px solid #cfdee8;
  border-radius: 5px;
  background: #fff;
  color: var(--navy);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.4;
  cursor: pointer;
  text-align: center;
}
button:hover, .button:hover { background: var(--ice); border-color: #aac5d7; }
.primary { background: var(--navy); border-color: var(--navy); color: #fff; }
.primary:hover { background: var(--blue); border-color: var(--blue); color: #fff; }
button:disabled, .button[aria-disabled='true'] { opacity: .55; cursor: not-allowed; }

/* Shared shop header; existing HTML needs no changes. */
.shop-header {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 26px;
  min-height: 112px;
  padding: 14px max(35px, calc((100% - 1250px) / 2));
  border-bottom: 1px solid #d9e7f0;
  background: rgba(236, 246, 252, .97);
  box-shadow: 0 2px 18px #08253b08;
  backdrop-filter: blur(12px);
}
.shop-logo { display: flex; flex: 0 0 auto; align-items: center; }
.shop-logo img { display: block; width: 175px; height: 70px; object-fit: contain; mix-blend-mode: multiply; }
.shop-header nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 14px 23px;
  margin-left: auto;
  min-width: 0;
}
.shop-header nav a, .shop-header .text-button {
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
}
.shop-header nav a:hover { color: var(--blue); }
.shop-header nav form { margin: 0; }
.text-button { min-height: 0; padding: 0; border: 0; background: transparent; box-shadow: none; font-weight: 400; }
.text-button:hover { background: transparent; color: var(--blue); }
.shop-langs { display: flex; flex: 0 0 auto; align-items: center; gap: 3px; font-size: 12px; }
.shop-langs a { padding: 8px 6px; border-bottom: 2px solid transparent; color: #557083; line-height: 1.5; }
.shop-langs a:hover { color: var(--navy); }
.shop-langs [aria-current]:not([aria-current='false']) {
  color: var(--navy);
  font-weight: 800;
  border-bottom-color: var(--navy);
  border-radius: 0;
  background: transparent;
}
.admin-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 28px;
  padding: 16px max(35px, calc((100% - 1250px) / 2));
  background: #08283f;
  color: #e7f2f9;
}
.admin-nav a { font-size: 13px; font-weight: 700; }
.admin-nav a:hover { color: #fff; text-decoration: underline; text-underline-offset: 5px; }
.shop-main { width: min(1250px, calc(100% - 70px)); min-height: 65vh; margin: auto; padding: 56px 0 80px; }

h1, h2, h3 { font-family: 'Manrope', 'DM Sans', system-ui, sans-serif; color: var(--navy); }
h1 { font-size: clamp(30px, 3.6vw, 48px); line-height: 1.15; letter-spacing: -1.5px; margin: 8px 0 28px; font-weight: 800; overflow-wrap: anywhere; }
h2 { font-size: 25px; line-height: 1.25; letter-spacing: -.7px; margin: 0 0 18px; }
h3 { font-size: 17px; line-height: 1.4; margin: 22px 0 14px; }
p { margin: 0 0 20px; }
.eyebrow { margin: 0 0 12px; color: #4b84a7; font-size: 11px; font-weight: 800; letter-spacing: 2px; }
.muted { color: var(--muted); font-size: 13px; }
.panel { min-width: 0; padding: 28px; margin-bottom: 24px; border: 1px solid var(--line); border-radius: 10px; background: #fff; box-shadow: 0 5px 22px #08253b04; }
.auth-panel { max-width: 470px; margin: 12px auto 30px; padding: 34px; }
.auth-panel h1 { font-size: clamp(28px, 3vw, 36px); }
.auth-panel > p:last-child { margin: 22px 0 0; font-size: 14px; }
.auth-panel > p a { color: var(--blue); font-weight: 700; text-decoration: underline; text-underline-offset: 4px; }
.stack { display: flex; flex-direction: column; gap: 19px; }
label { display: flex; flex-direction: column; gap: 7px; min-width: 0; font-size: 13px; font-weight: 700; }
input, textarea, select {
  width: 100%;
  min-width: 0;
  padding: 11px 13px;
  border: 1px solid #cfdee8;
  border-radius: 5px;
  background: #fbfdff;
  color: var(--navy);
  font-weight: 400;
  line-height: 1.5;
}
input::placeholder, textarea::placeholder { color: #7b8f9f; opacity: 1; }
input:focus, textarea:focus, select:focus { border-color: #4b84a7; outline: 3px solid #1b80b922; outline-offset: 1px; background: #fff; }
textarea { resize: vertical; min-height: 120px; }
input[type='file'] { padding: 8px; font-size: 13px; background: #fff; }
input[type='file']::file-selector-button { margin-right: 12px; padding: 7px 11px; border: 1px solid #cfdee8; border-radius: 4px; background: var(--ice); color: var(--navy); font: inherit; cursor: pointer; }
.google { width: 100%; margin-top: 22px; border-color: #b9d1e1; background: #f4f9fc; }
.form-grid, .translation-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
fieldset { min-width: 0; margin: 0; padding: 20px; border: 1px solid var(--line); border-radius: 7px; background: #fbfdff; }
fieldset label + label { margin-top: 16px; }
legend { padding: 0 8px; font-size: 12px; font-weight: 800; color: var(--blue); }
.save { align-self: flex-start; min-width: 180px; }
.page-title { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 28px; }
.page-title h1 { margin-bottom: 0; }
.filters { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; margin: 24px 0; }
.filters input { flex: 1 1 220px; max-width: 440px; }
.filters input[type='hidden'] { display: none; }
.filters select { flex: 0 1 220px; width: 220px; }
.filters button { flex: 0 0 auto; }
.table-wrap { max-width: 100%; overflow-x: auto; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
table { width: 100%; border-collapse: collapse; text-align: left; }
th, td { padding: 17px 18px; border-bottom: 1px solid var(--line); font-size: 14px; vertical-align: middle; }
th { background: #edf5fa; color: #456a83; font-size: 11px; font-weight: 800; letter-spacing: .7px; text-transform: uppercase; }
tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: #f8fbfd; }
td a { color: var(--blue); font-weight: 700; }
td a:hover { text-decoration: underline; text-underline-offset: 4px; }
.badge { display: inline-block; padding: 5px 10px; border: 1px solid #d5e4ed; border-radius: 5px; background: #edf5fa; color: #456a83; font-size: 12px; white-space: nowrap; }
.badge.published { background: #dfeff8; border-color: #b9d8e9; color: #14537d; }
.badge.archived { background: #f3f6f8; border-color: #e1e7ec; color: var(--muted); }
.notice { margin: 0 0 24px; padding: 16px 20px; border: 1px solid #cfdee8; border-left: 4px solid #4b84a7; border-radius: 6px; background: #edf5fa; color: #294d65; font-size: 14px; }
.error { background: #fff1ed; border-color: #f0d2c9; border-left-color: #bd643e; color: #8b3b29; }
.dashboard-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 290px), 1fr)); gap: 22px; }
.dashboard-card { min-height: 220px; margin-bottom: 0; color: var(--navy); transition: border-color .2s, box-shadow .2s; }
.dashboard-card:hover { border-color: #abcbdF; box-shadow: 0 8px 25px #08253b0c; }
.dashboard-card > span { display: block; margin-bottom: 22px; color: #4b84a7; font-size: 10px; font-weight: 800; letter-spacing: 2px; }
.dashboard-card p { color: var(--muted); font-size: 14px; }
.stats { display: flex; flex-wrap: wrap; gap: 20px 28px; margin-top: 25px; }
.stats strong { display: block; font-size: 32px; font-weight: 800; }
.stats small { color: var(--muted); font-size: 11px; }
.image-editor { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 190px), 1fr)); gap: 22px; }
.image-editor article { min-width: 0; padding: 14px; border: 1px solid var(--line); border-radius: 7px; background: #fbfdff; }
.image-editor img { display: block; width: 100%; height: 165px; margin-bottom: 14px; object-fit: contain; background: #fff; border-radius: 4px; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; }
.danger { color: var(--danger); }
.danger:hover { background: #fff1ed; border-color: #e4bfb4; }
.variant-form { display: grid; grid-template-columns: 1.4fr 1.2fr .7fr .9fr .7fr .8fr auto auto; gap: 10px; align-items: end; padding: 18px 0; border-bottom: 1px solid var(--line); }
.variant-form label { font-size: 11px; }
.variant-form button { padding: 11px; }
.user-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; margin: 0; }
.user-row > div { flex: 1 1 220px; min-width: 0; overflow-wrap: anywhere; }
.check { flex-direction: row; align-items: center; }
.check input { flex: 0 0 auto; width: 17px; height: 17px; accent-color: var(--blue); }
.pagination { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 14px 28px; padding: 26px 0; font-size: 14px; }
.pagination a { color: var(--blue); font-weight: 700; }
.pagination a:hover { text-decoration: underline; text-underline-offset: 4px; }
.pagination span { display: grid; place-items: center; min-width: 34px; min-height: 34px; border-radius: 5px; background: var(--ice); }

/* Catalog and product page. Images stay uncropped. */
.product-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; margin-top: 30px; }
.product-card { display: flex; flex-direction: column; min-width: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 8px; background: #fff; transition: border-color .2s, box-shadow .2s; }
.product-card:hover { border-color: #b9d1e1; box-shadow: 0 8px 26px #08253b0c; }
.product-card img { display: block; width: 100%; height: 285px; padding: 20px; object-fit: contain; background: #fff; }
.product-info { display: flex; flex: 1; flex-direction: column; align-items: flex-start; padding: 20px 22px 24px; border-top: 1px solid #edf3f7; }
.product-info small { color: #4b84a7; font-size: 11px; font-weight: 800; letter-spacing: 1px; text-transform: uppercase; overflow-wrap: anywhere; }
.product-info h2 { margin: 10px 0 18px; font-size: 20px; line-height: 1.35; letter-spacing: -.5px; overflow-wrap: anywhere; }
.product-info > strong { margin-top: auto; color: var(--navy); font-size: 20px; font-weight: 800; }
.image-placeholder { display: grid; place-items: center; height: 285px; padding: 20px; background: linear-gradient(145deg, #eaf4fa, #d5e6f0); color: #4b84a7; font-size: 13px; font-weight: 800; letter-spacing: 2px; }
.product-detail { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 60px; align-items: start; margin-top: 32px; }
.product-detail > section, .gallery { min-width: 0; }
.product-detail h1 { font-size: clamp(28px, 3vw, 42px); }
.gallery img { display: block; width: 100%; height: auto; padding: 18px; margin-bottom: 20px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.large-price { margin-bottom: 4px; color: var(--blue); font-size: 34px; font-weight: 800; }
.product-detail section > small { color: var(--muted); font-size: 12px; }
.description { margin-top: 28px; white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.75; }
.shop-footer { padding: 42px max(35px, calc((100% - 1250px) / 2)); background: #061e30; color: #c6d8e3; font-size: 13px; }
.shop-footer > strong { color: #fff; font-size: 14px; }
.shop-footer p { margin: 14px 0 0; line-height: 1.9; overflow-wrap: anywhere; }
.shop-footer a { text-decoration: underline; text-underline-offset: 3px; }
.shop-footer a:hover { color: #fff; }
summary { cursor: pointer; color: var(--blue); font-weight: 800; }
details[open] summary { margin-bottom: 20px; }

@media (max-width: 1000px) {
  .shop-header { gap: 16px; flex-wrap: wrap; }
  .shop-header nav { gap: 12px 16px; }
  .variant-form { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .product-detail { gap: 30px; }
  .dashboard-card h2 { font-size: 23px; }
}

@media (max-width: 760px) {
  html { scroll-padding-top: 155px; }
  .shop-header { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 14px; min-height: 78px; padding: 10px 18px 12px; }
  .shop-logo img { width: 150px; height: 52px; }
  .shop-langs { grid-column: 2; grid-row: 1; justify-self: end; }
  .shop-header nav { grid-column: 1 / -1; grid-row: 2; justify-content: flex-start; width: 100%; margin: 0; gap: 2px 18px; }
  .shop-header nav a, .shop-header .text-button { display: inline-flex; align-items: center; min-height: 36px; font-size: 12px; }
  .admin-nav { gap: 10px 20px; padding: 14px 18px; }
  .admin-nav a { font-size: 12px; }
  .shop-main { width: calc(100% - 36px); padding: 34px 0 55px; }
  .product-detail { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .shop-footer { padding: 32px 18px; }
}

@media (max-width: 600px) {
  h1 { font-size: 30px; letter-spacing: -1px; }
  h2 { font-size: 23px; }
  .panel { padding: 19px; }
  .auth-panel { padding: 24px 20px; margin-top: 4px; }
  .form-grid, .translation-grid { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  fieldset { padding: 16px; }
  input, textarea, select { font-size: 16px; }
  .filters { align-items: stretch; }
  .filters input, .filters select { flex: 1 1 100%; width: 100%; max-width: none; }
  .filters button { flex: 1 1 auto; }
  .product-grid { gap: 12px; margin-top: 24px; }
  .product-card img, .product-card .image-placeholder { height: 180px; padding: 10px; }
  .product-info { padding: 13px 12px 16px; }
  .product-info small { font-size: 9px; letter-spacing: .7px; }
  .product-info h2 { font-size: 16px; letter-spacing: -.3px; margin: 8px 0 14px; }
  .product-info > strong { font-size: 18px; }
  .image-placeholder { font-size: 10px; letter-spacing: .5px; }
  .variant-form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .page-title { flex-direction: column; align-items: flex-start; margin-bottom: 22px; }
  .dashboard-grid { grid-template-columns: minmax(0, 1fr); }
  .dashboard-card { min-height: 0; }
  .user-row { align-items: flex-start; gap: 16px; }
  .user-row > div { flex-basis: 100%; }
  .notice { padding: 14px 16px; font-size: 13px; }
  .stats { gap: 16px 24px; }
  th, td { padding: 13px 12px; }
  .actions > button { flex: 1 1 auto; }
  .gallery img { padding: 12px; }
  .large-price { font-size: 30px; }
}

@media (max-width: 380px) {
  .shop-logo img { width: 125px; }
  .shop-langs a { padding: 8px 4px; }
  .shop-header nav { gap: 2px 12px; }
  .product-card img, .product-card .image-placeholder { height: 150px; }
  .product-info { padding: 12px 10px; }
  .product-info h2 { font-size: 15px; }
}

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