﻿:root {
  --bg-a: #f2f8ff;
  --bg-b: #fff4ea;
  --surface: #ffffff;
  --surface-2: #f8fbff;
  --text: #12233b;
  --muted: #57708e;
  --line: #d6e4f4;
  --fire: #e26b1d;
  --ice: #0f8bd6;
  --shadow: 0 16px 36px rgba(18, 35, 59, 0.12);
  --shadow-soft: 0 8px 20px rgba(18, 35, 59, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--text);
  font-family: 'Outfit', sans-serif;
  background:
    radial-gradient(circle at 8% -5%, rgba(226, 107, 29, 0.22), transparent 27%),
    radial-gradient(circle at 100% 0%, rgba(15, 139, 214, 0.2), transparent 28%),
    linear-gradient(160deg, var(--bg-a), var(--bg-b));
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 0.9rem clamp(1rem, 4vw, 2.6rem);
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.brand h1,
.hero h2,
h2,
h3 {
  margin: 0;
  font-family: 'Bebas Neue', sans-serif;
  letter-spacing: 1px;
}

.brand p {
  margin: 0;
  color: var(--muted);
}

.logo {
  width: 52px;
  height: 52px;
}

.admin-link,
button,
.hero-cta {
  border: 1px solid #aac5df;
  background: linear-gradient(135deg, #ffffff 0%, #eaf5ff 50%, #fff3e8 100%);
  color: #15395e;
  text-decoration: none;
  border-radius: 12px;
  padding: 0.55rem 1rem;
  cursor: pointer;
  font: inherit;
  transition: transform 140ms ease, box-shadow 140ms ease, border-color 140ms ease;
}

.admin-link:hover,
button:hover,
.hero-cta:hover {
  transform: translateY(-2px);
  border-color: #7fa5c9;
  box-shadow: var(--shadow-soft);
}

.hero-cta.secondary {
  background: linear-gradient(135deg, #fff 0%, #fff3e6 100%);
}

.site-main,
.admin-main {
  width: min(1180px, 94vw);
  margin: 1.25rem auto 2rem;
  display: grid;
  gap: 1rem;
}

.hero,
.shop-wrap,
.company-card,
.admin-card,
.detail-card {
  border: 1px solid var(--line);
  border-radius: 22px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.hero {
  padding: 1.4rem;
  background:
    radial-gradient(circle at 12% 8%, rgba(226, 107, 29, 0.16), transparent 35%),
    radial-gradient(circle at 88% 12%, rgba(15, 139, 214, 0.18), transparent 38%),
    linear-gradient(150deg, #ffffff 0%, #f7fbff 100%);
}

.hero h2 {
  font-size: clamp(2rem, 4vw, 2.9rem);
}

.hero p {
  margin: 0.55rem 0 0;
  color: var(--muted);
  max-width: 760px;
  line-height: 1.5;
}

.hero-actions {
  margin-top: 1rem;
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.shop-wrap,
.company-card,
.admin-card,
.detail-card {
  padding: 1.1rem;
}

.highlights {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.8rem;
}

.highlights article {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: linear-gradient(155deg, #ffffff 0%, #f7fbff 100%);
  padding: 0.85rem;
}

.highlights strong {
  font-size: 1.15rem;
  color: #1f4d78;
}

.highlights span {
  color: var(--muted);
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.8rem;
}

.section-head h3,
.company-card h3,
.admin-card h2 {
  font-size: 2.1rem;
  line-height: 1;
  background: linear-gradient(90deg, #184269 0%, #0f8bd6 60%, #e26b1d 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.filters {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  color: var(--muted);
}

select,
input,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  color: var(--text);
  padding: 0.62rem 0.72rem;
  font: inherit;
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: #86b8e0;
  box-shadow: 0 0 0 4px rgba(15, 139, 214, 0.15);
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(245px, 1fr));
  gap: 0.95rem;
  margin-top: 0.9rem;
}

.catalog-footer {
  margin-top: 1rem;
  display: grid;
  gap: 0.7rem;
  justify-items: center;
}

.muted-line {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.pagination {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
  justify-content: center;
}

.page-btn {
  min-width: 40px;
  height: 36px;
  padding: 0 0.65rem;
  border-radius: 10px;
}

.page-btn.active {
  background: linear-gradient(135deg, #dff0ff 0%, #ffe7d5 100%);
  border-color: #7fa5c9;
  font-weight: 700;
}

.page-btn:disabled {
  opacity: 0.55;
  cursor: default;
  transform: none;
  box-shadow: none;
}

.page-dots {
  color: var(--muted);
  padding: 0 0.2rem;
}

.product-card {
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  background: linear-gradient(160deg, #fff 0%, #f8fbff 100%);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.product-card:hover {
  transform: translateY(-4px);
  border-color: #a9c9e7;
  box-shadow: 0 14px 26px rgba(15, 64, 110, 0.14);
}

.product-card:focus-visible {
  outline: 3px solid rgba(15, 139, 214, 0.35);
  outline-offset: 2px;
}

.product-image {
  width: 100%;
  height: 180px;
  object-fit: cover;
}

.product-content {
  padding: 0.9rem;
  display: grid;
  gap: 0.55rem;
}

.product-content h4 {
  margin: 0;
  font-size: 1.04rem;
}

.about {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
  font-size: 0.92rem;
}

.chip {
  display: inline-block;
  width: fit-content;
  font-size: 0.76rem;
  color: #1f507d;
  background: linear-gradient(90deg, rgba(15, 139, 214, 0.16), rgba(226, 107, 29, 0.16));
  border: 1px solid #b8d3eb;
  border-radius: 999px;
  padding: 0.2rem 0.62rem;
}

.meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.7rem;
}

.stock {
  color: #2c638f;
  font-size: 0.84rem;
}

.price {
  color: #c14f0c;
  font-size: 1.08rem;
  font-weight: 700;
}

.company-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.9rem;
  margin-top: 0.9rem;
}

.company-grid.two-col {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.company-grid article {
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 0.95rem;
  background: linear-gradient(160deg, #fff 0%, #f7fbff 100%);
}

.company-grid h4 {
  margin: 0 0 0.45rem;
  color: #2f4f70;
}

.company-grid p {
  margin: 0.32rem 0;
}

.company-grid a {
  color: var(--ice);
}

.map-embed-wrap {
  margin-top: 1rem;
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
}

.map-embed-wrap iframe {
  width: 100%;
  height: 360px;
  border: 0;
  display: block;
}

.footer {
  width: min(1180px, 94vw);
  margin: 0 auto 1.7rem;
  text-align: center;
  color: var(--muted);
}

.admin-form {
  display: grid;
  gap: 0.75rem;
}

.compact-form {
  max-width: 420px;
}

.admin-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.7rem;
}

.admin-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.between {
  justify-content: space-between;
}

.checkbox {
  display: flex;
  gap: 0.45rem;
  align-items: center;
}

.checkbox input {
  width: auto;
}

.category-manager {
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 0.85rem;
  margin-bottom: 0.95rem;
  background: linear-gradient(155deg, #fff, #f6fbff);
}

.category-list {
  margin-top: 0.7rem;
  display: grid;
  gap: 0.5rem;
}

.category-item {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.55rem 0.65rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #fff;
}

.range-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(100px, 1fr));
  gap: 0.4rem;
  width: 100%;
}

.admin-message {
  min-height: 1.3rem;
  color: #0e7490;
}

.admin-list {
  margin-top: 0.8rem;
  display: grid;
  gap: 0.65rem;
}

.admin-item {
  border: 1px solid var(--line);
  border-radius: 14px;
  display: grid;
  grid-template-columns: 130px 1fr;
  overflow: hidden;
  background: linear-gradient(160deg, #fff 0%, #f8fbff 100%);
}

.thumb {
  width: 100%;
  height: 100%;
  min-height: 118px;
  object-fit: cover;
}

.admin-item-content {
  padding: 0.8rem;
}

.admin-item-content h3 {
  margin: 0;
  font-size: 1.1rem;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(260px, 420px) 1fr;
  gap: 1rem;
}

.detail-media {
  position: sticky;
  top: 88px;
  align-self: start;
}

.detail-image {
  width: 100%;
  border-radius: 14px;
  object-fit: cover;
  min-height: 320px;
  max-height: 460px;
}

.detail-thumbs {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.65rem;
  flex-wrap: wrap;
}

.thumb-btn {
  padding: 0;
  border-radius: 10px;
  border: 2px solid transparent;
  background: transparent;
  overflow: hidden;
}

.thumb-btn img {
  width: 72px;
  height: 72px;
  object-fit: cover;
  display: block;
}

.thumb-btn.active {
  border-color: #0f8bd6;
}

.detail-content h2 {
  font-size: clamp(2rem, 4vw, 2.8rem);
}

.product-path {
  margin: 0 0 0.45rem;
  color: var(--muted);
  font-size: 0.88rem;
}

.detail-meta {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-top: 1rem;
  flex-wrap: wrap;
}

.detail-meta-card {
  border: 1px solid var(--line);
  background: linear-gradient(165deg, #fff 0%, #f6fbff 100%);
  border-radius: 12px;
  padding: 0.75rem 0.8rem;
}

.mini-note {
  color: var(--muted);
  font-size: 0.82rem;
}

.detail-actions {
  margin-top: 1.1rem;
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.kw-picker {
  display: grid;
  gap: 0.35rem;
  margin-bottom: 0.6rem;
}

.kw-picker label {
  color: #2f4f70;
  font-size: 0.9rem;
}

.range-table-wrap {
  margin-top: 1rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.75rem;
  background: var(--surface-2);
}

.range-table-wrap h3 {
  margin: 0 0 0.5rem;
  font-size: 1.2rem;
  color: #184269;
}

.range-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
}

.range-table th,
.range-table td {
  border-bottom: 1px solid var(--line);
  padding: 0.45rem 0.3rem;
  text-align: left;
}

.ghost {
  background: #fff;
}

.hidden {
  display: none;
}

.empty {
  margin: 1rem 0;
  color: var(--muted);
}

@media (max-width: 900px) {
  .highlights,
  .company-grid,
  .company-grid.two-col {
    grid-template-columns: 1fr;
  }

  .product-grid {
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  }

  .detail-layout {
    grid-template-columns: 1fr;
  }

  .detail-media {
    position: static;
  }

  .detail-image {
    min-height: 220px;
    max-height: 320px;
  }
}

@media (max-width: 640px) {
  .topbar {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.6rem;
  }

  .brand h1 {
    font-size: 1.25rem;
    line-height: 1.1;
  }

  .brand p {
    font-size: 0.84rem;
  }

  .logo {
    width: 42px;
    height: 42px;
  }

  .site-main,
  .admin-main {
    width: min(1180px, 96vw);
  }

  .hero,
  .shop-wrap,
  .company-card,
  .admin-card,
  .detail-card {
    border-radius: 16px;
    padding: 0.9rem;
  }

  .hero h2 {
    font-size: 1.8rem;
  }

  .section-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .product-grid {
    grid-template-columns: 1fr;
  }

  .page-btn {
    min-width: 34px;
    height: 34px;
    padding: 0 0.45rem;
    font-size: 0.88rem;
  }

  .product-image {
    height: 200px;
  }

  .range-row {
    grid-template-columns: 1fr;
  }

  .admin-grid {
    grid-template-columns: 1fr;
  }

  .admin-item {
    grid-template-columns: 1fr;
  }

  .thumb {
    height: 180px;
  }
}

/* Launch polish */
:root {
  --bg-a: #f4f7fb;
  --bg-b: #fff7ef;
  --surface: #ffffff;
  --surface-2: #f7fafc;
  --text: #102033;
  --muted: #64748b;
  --line: #d8e1eb;
  --fire: #d9651f;
  --ice: #087ec1;
  --ink: #1f2937;
  --success: #17865b;
  --shadow: 0 14px 34px rgba(15, 32, 51, 0.1);
  --shadow-soft: 0 8px 18px rgba(15, 32, 51, 0.08);
}

body {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(255, 255, 255, 0.92)),
    radial-gradient(circle at 0 0, rgba(8, 126, 193, 0.16), transparent 26rem),
    radial-gradient(circle at 100% 8rem, rgba(217, 101, 31, 0.14), transparent 24rem),
    linear-gradient(135deg, var(--bg-a), var(--bg-b));
}

.topbar {
  border-bottom-color: rgba(16, 32, 51, 0.08);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 8px 28px rgba(15, 32, 51, 0.06);
}

.brand h1 {
  color: var(--ink);
  font-family: 'Outfit', sans-serif;
  font-size: 1.12rem;
  font-weight: 800;
  letter-spacing: 0;
}

.brand p {
  font-size: 0.9rem;
}

.logo {
  border-radius: 8px;
  box-shadow: var(--shadow-soft);
}

.admin-link,
button,
.hero-cta {
  border-radius: 8px;
  border-color: #c8d7e6;
  background: #fff;
  color: #17324d;
  font-weight: 700;
}

.hero-cta {
  background: var(--ice);
  border-color: var(--ice);
  color: #fff;
}

.hero-cta.secondary,
.admin-link {
  background: #fff;
  color: #17324d;
}

.hero,
.shop-wrap,
.company-card,
.admin-card,
.detail-card {
  border-radius: 8px;
  border-color: rgba(16, 32, 51, 0.1);
}

.hero {
  min-height: 260px;
  display: grid;
  align-content: end;
  background:
    linear-gradient(90deg, rgba(16, 32, 51, 0.78), rgba(16, 32, 51, 0.2)),
    url('https://images.unsplash.com/photo-1621905252507-b35492cc74b4?auto=format&fit=crop&w=1800&q=80') center/cover;
  color: #fff;
}

.hero h2 {
  max-width: 760px;
  font-family: 'Outfit', sans-serif;
  font-size: clamp(2rem, 5vw, 3.45rem);
  font-weight: 800;
  letter-spacing: 0;
  line-height: 1.04;
}

.hero p {
  color: rgba(255, 255, 255, 0.86);
  font-size: 1.05rem;
}

.highlights article,
.company-grid article,
.product-card,
.category-manager,
.admin-item {
  border-radius: 8px;
}

.highlights article {
  display: grid;
  gap: 0.25rem;
  background: #fff;
  border-left: 4px solid var(--ice);
}

.highlights article:nth-child(2) {
  border-left-color: var(--success);
}

.highlights article:nth-child(3) {
  border-left-color: var(--fire);
}

.section-head h3,
.company-card h3,
.admin-card h2 {
  color: var(--ink);
  background: none;
  font-family: 'Outfit', sans-serif;
  font-size: clamp(1.35rem, 2.4vw, 1.8rem);
  font-weight: 800;
  letter-spacing: 0;
}

.filters {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0.35rem;
}

.filters select {
  min-width: 170px;
  border: 0;
  background: transparent;
}

.product-grid {
  grid-template-columns: repeat(auto-fill, minmax(255px, 1fr));
  gap: 1rem;
}

.product-card {
  display: grid;
  grid-template-rows: 190px 1fr;
  background: #fff;
  box-shadow: 0 8px 20px rgba(15, 32, 51, 0.08);
}

.product-card:hover {
  transform: translateY(-5px);
  border-color: rgba(8, 126, 193, 0.35);
  box-shadow: 0 18px 34px rgba(15, 32, 51, 0.14);
}

.product-image {
  height: 100%;
  background: #eef4f8;
}

.product-content {
  align-content: start;
  gap: 0.7rem;
}

.product-content h4 {
  color: var(--ink);
  font-size: 1.08rem;
  line-height: 1.25;
}

.about {
  display: -webkit-box;
  min-height: 3.95em;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.chip {
  border-radius: 999px;
  background: #eef7ff;
  border-color: #cbe2f5;
  color: #075985;
  font-weight: 700;
}

.meta {
  align-items: flex-end;
  border-top: 1px solid var(--line);
  padding-top: 0.7rem;
}

.price {
  color: var(--fire);
  font-size: 1.12rem;
}

.stock {
  color: var(--success);
  line-height: 1.25;
}

.page-btn.active {
  background: var(--ice);
  border-color: var(--ice);
  color: #fff;
}

.company-grid.two-col {
  grid-template-columns: minmax(260px, 0.8fr) minmax(320px, 1.2fr);
}

.company-grid article {
  background: #fff;
}

.map-embed-wrap {
  border-radius: 8px;
  box-shadow: var(--shadow-soft);
}

.detail-card {
  padding: clamp(0.8rem, 2vw, 1.25rem);
}

.detail-layout {
  grid-template-columns: minmax(280px, 500px) minmax(0, 1fr);
  gap: clamp(1rem, 3vw, 2rem);
}

.detail-media {
  top: 96px;
}

.detail-image {
  aspect-ratio: 4 / 3;
  min-height: auto;
  max-height: none;
  border-radius: 8px;
  box-shadow: var(--shadow-soft);
}

.detail-thumbs {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
}

.thumb-btn {
  border-radius: 8px;
}

.thumb-btn img {
  width: 100%;
  height: 74px;
}

.product-path {
  color: #64748b;
}

.detail-content h2 {
  color: var(--ink);
  font-family: 'Outfit', sans-serif;
  font-size: clamp(1.9rem, 4vw, 3rem);
  font-weight: 800;
  letter-spacing: 0;
  line-height: 1.08;
}

.detail-meta-card,
.range-table-wrap {
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow-soft);
}

.detail-meta-card {
  align-items: center;
  justify-content: space-between;
}

.detail-meta-card .price {
  font-size: clamp(1.35rem, 3vw, 1.8rem);
}

.kw-picker select {
  background: #f8fafc;
}

.admin-main {
  max-width: 1040px;
}

.admin-card {
  box-shadow: var(--shadow-soft);
}

.category-item {
  border-radius: 8px;
  gap: 0.7rem;
}

@media (max-width: 760px) {
  .topbar {
    position: static;
  }

  .admin-link {
    width: 100%;
    text-align: center;
  }

  .hero {
    min-height: 300px;
    padding: 1.05rem;
  }

  .hero h2 {
    font-size: 2.15rem;
  }

  .hero-actions .hero-cta {
    width: 100%;
    justify-content: center;
  }

  .highlights {
    gap: 0.65rem;
  }

  .product-grid {
    grid-template-columns: 1fr;
  }

  .product-card {
    grid-template-rows: 220px 1fr;
  }

  .filters {
    width: 100%;
  }

  .filters select {
    min-width: 0;
  }

  .company-grid.two-col {
    grid-template-columns: 1fr;
  }

  .map-embed-wrap iframe {
    height: 280px;
  }

  .detail-layout {
    grid-template-columns: 1fr;
  }

  .detail-meta-card {
    display: grid;
    gap: 0.45rem;
  }

  .detail-actions .hero-cta {
    width: 100%;
  }

  .category-item {
    align-items: stretch;
    flex-direction: column;
  }
}
