* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--surface-tint, #fff5f8);
  color: #252027;
  font-family: var(--font-family);
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font: inherit;
}

.topbar {
  align-items: center;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(37, 32, 39, 0.08);
  display: flex;
  justify-content: space-between;
  left: 0;
  min-height: 64px;
  padding: 12px clamp(16px, 4vw, 44px);
  position: sticky;
  right: 0;
  top: 0;
  z-index: 20;
}

.brand {
  align-items: center;
  display: inline-flex;
  font-weight: 800;
  gap: 10px;
}

.brand-mark {
  align-items: center;
  background: var(--primary);
  border-radius: 8px;
  color: #fff;
  display: inline-flex;
  height: 34px;
  justify-content: center;
  width: 34px;
}

.topbar nav {
  display: flex;
  gap: 8px;
}

.topbar nav a {
  border-radius: 8px;
  padding: 9px 11px;
}

.topbar nav a:hover {
  background: rgba(0, 0, 0, 0.05);
}

.hero {
  align-items: center;
  display: grid;
  gap: 28px;
  grid-template-columns: 1.02fr 0.98fr;
  min-height: calc(100svh - 64px);
  padding: clamp(24px, 5vw, 70px);
}

.hero-copy {
  max-width: 680px;
}

.eyebrow {
  color: var(--secondary);
  display: block;
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0;
  margin-bottom: 14px;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

.hero h1 {
  font-size: clamp(2.35rem, 7vw, 5.75rem);
  line-height: 0.95;
  margin-bottom: 18px;
  max-width: 820px;
}

.hero p {
  color: #5d535f;
  font-size: clamp(1rem, 2vw, 1.24rem);
  line-height: 1.6;
  max-width: 620px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 26px;
}

.btn {
  align-items: center;
  background: #fff;
  border: 1px solid rgba(37, 32, 39, 0.12);
  border-radius: 8px;
  color: #252027;
  cursor: pointer;
  display: inline-flex;
  font-weight: 800;
  justify-content: center;
  min-height: 44px;
  padding: 11px 16px;
}

.btn.primary {
  background: var(--button);
  border-color: var(--button);
  color: #fff;
}

.btn.ghost {
  background: rgba(255, 255, 255, 0.72);
}

.btn.small {
  min-height: 36px;
  padding: 8px 10px;
}

.btn.full {
  width: 100%;
}

.hero-visual {
  align-items: center;
  background:
    radial-gradient(circle at 40% 32%, rgba(255, 255, 255, 0.96), rgba(255, 255, 255, 0.12) 62%),
    linear-gradient(145deg, color-mix(in srgb, var(--primary) 28%, #fff), color-mix(in srgb, var(--secondary) 28%, #fff));
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 24px;
  display: flex;
  justify-content: center;
  min-height: 420px;
  overflow: hidden;
  position: relative;
}

.hero-bouquet {
  height: 330px;
  position: relative;
  width: min(360px, 76vw);
}

.hero-bouquet::after {
  background: linear-gradient(145deg, #b08968, #f1c27d);
  border-radius: 18px 18px 80px 80px;
  bottom: 0;
  content: "";
  height: 160px;
  left: 50%;
  position: absolute;
  transform: translateX(-50%);
  width: 160px;
}

.hero-bouquet span {
  background: var(--primary);
  border: 8px solid rgba(255, 255, 255, 0.8);
  border-radius: 50%;
  box-shadow: 0 22px 40px rgba(122, 31, 76, 0.2);
  height: 120px;
  position: absolute;
  width: 120px;
  z-index: 2;
}

.hero-bouquet span:nth-child(1) { left: 18px; top: 96px; }
.hero-bouquet span:nth-child(2) { left: 78px; top: 30px; }
.hero-bouquet span:nth-child(3) { left: 160px; top: 74px; }
.hero-bouquet span:nth-child(4) { background: #fff; left: 112px; top: 122px; }
.hero-bouquet span:nth-child(5) { background: #f9b208; left: 210px; top: 142px; }

.category-strip {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 0 clamp(16px, 5vw, 70px) 24px;
}

.category-strip a {
  background: #fff;
  border: 1px solid rgba(37, 32, 39, 0.08);
  border-radius: 8px;
  flex: 0 0 auto;
  font-weight: 800;
  padding: 13px 16px;
}

.content-band,
.panel {
  padding: clamp(22px, 4vw, 44px);
}

.section-heading {
  align-items: end;
  display: flex;
  gap: 16px;
  justify-content: space-between;
  margin-bottom: 18px;
}

.section-heading h1,
.section-heading h2 {
  margin-bottom: 0;
}

.section-heading span,
.muted,
small {
  color: #756b77;
}

.store-grid,
.builder-grid,
.product-admin-grid,
.metric-grid,
.report-grid {
  display: grid;
  gap: 14px;
}

.store-grid {
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
}

.store-card,
.choice-card,
.panel,
.auth-card,
.product-editor,
.summary-panel,
.desktop-categories,
.admin-sidebar,
.report-grid article,
.metric-grid article {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(37, 32, 39, 0.08);
  border-radius: 8px;
  box-shadow: 0 18px 40px rgba(69, 28, 49, 0.07);
}

.store-card {
  padding: 18px;
}

.product-flower {
  background:
    radial-gradient(circle at 40% 35%, #fff 0 10%, transparent 11%),
    var(--item-color, var(--primary));
  border: 5px solid #fff;
  border-radius: 50%;
  box-shadow: 0 10px 22px rgba(37, 32, 39, 0.12);
  display: block;
  height: 74px;
  margin-bottom: 14px;
  width: 74px;
}

.whatsapp-float {
  background: #25d366;
  border-radius: 999px;
  bottom: 18px;
  color: #fff;
  font-weight: 900;
  padding: 13px 16px;
  position: fixed;
  right: 18px;
  z-index: 15;
}

.builder-shell {
  display: grid;
  gap: 16px;
  grid-template-columns: 180px minmax(0, 1fr) 360px;
  padding: 18px;
}

.desktop-categories,
.summary-panel {
  align-self: start;
  padding: 16px;
  position: sticky;
  top: 82px;
}

.desktop-categories {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.desktop-categories a {
  border-radius: 8px;
  padding: 10px;
}

.desktop-categories a:hover {
  background: rgba(0, 0, 0, 0.05);
}

.builder-main {
  min-width: 0;
}

.builder-progress {
  background: rgba(255, 255, 255, 0.9);
  border-radius: 8px;
  margin-bottom: 14px;
  padding: 14px;
}

progress {
  accent-color: var(--primary);
  display: block;
  height: 10px;
  margin-top: 8px;
  width: 100%;
}

.bouquet-preview {
  align-items: center;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.94), color-mix(in srgb, var(--primary) 12%, #fff));
  border-radius: 8px;
  display: grid;
  gap: 16px;
  grid-template-columns: 180px 1fr;
  margin-bottom: 14px;
  min-height: 190px;
  padding: 18px;
}

.bouquet-art {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  justify-content: center;
  min-height: 150px;
  position: relative;
}

.bouquet-art span {
  background: var(--item-color);
  border: 4px solid #fff;
  border-radius: 50%;
  height: 46px;
  transform: translateY(calc((var(--i) % 4) * 4px));
  width: 46px;
}

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

.choice-card {
  align-items: center;
  display: grid;
  gap: 12px;
  grid-template-columns: 70px minmax(0, 1fr);
  padding: 14px;
}

.choice-card .product-flower {
  height: 58px;
  margin: 0;
  width: 58px;
}

.choice-card h3 {
  margin-bottom: 4px;
}

.qty-control {
  align-items: center;
  display: grid;
  gap: 8px;
  grid-column: 1 / -1;
  grid-template-columns: 42px 1fr 42px;
}

.qty-control button {
  background: var(--primary);
  border: 0;
  border-radius: 8px;
  color: #fff;
  cursor: pointer;
  font-size: 1.2rem;
  font-weight: 900;
  height: 40px;
}

.qty-control strong {
  text-align: center;
}

.summary-panel label,
.auth-card label,
.settings-form label,
.product-editor label {
  color: #4c424d;
  display: flex;
  flex-direction: column;
  font-size: 0.86rem;
  font-weight: 800;
  gap: 6px;
  margin-bottom: 10px;
}

input,
select,
textarea {
  background: #fff;
  border: 1px solid rgba(37, 32, 39, 0.14);
  border-radius: 8px;
  min-height: 40px;
  padding: 9px 10px;
  width: 100%;
}

.summary-item,
.total-line {
  align-items: center;
  border-bottom: 1px solid rgba(37, 32, 39, 0.08);
  display: flex;
  justify-content: space-between;
  padding: 9px 0;
}

.total-line {
  border-bottom: 0;
  font-size: 1.15rem;
  margin: 10px 0;
}

.mobile-bottom {
  display: none;
}

.auth-shell {
  display: grid;
  min-height: calc(100svh - 120px);
  place-items: center;
  padding: 24px;
}

.auth-card {
  max-width: 420px;
  padding: 24px;
  width: 100%;
}

.notice {
  background: #fff0f3;
  border: 1px solid #ffc2d1;
  border-radius: 8px;
  color: #8a1538;
  padding: 10px;
}

.success {
  background: #e8f5e9;
  border: 1px solid #a5d6a7;
  border-radius: 8px;
  color: #1b5e20;
  margin: 0 0 14px;
  padding: 10px;
}

.admin-layout {
  display: grid;
  gap: 16px;
  grid-template-columns: 240px minmax(0, 1fr);
  padding: 18px;
}

.admin-sidebar {
  align-self: start;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 16px;
  position: sticky;
  top: 82px;
}

.admin-sidebar a,
.link-button {
  background: transparent;
  border: 0;
  border-radius: 8px;
  color: #332a34;
  cursor: pointer;
  padding: 10px;
  text-align: left;
}

.admin-sidebar a:hover,
.link-button:hover {
  background: rgba(0, 0, 0, 0.05);
}

.admin-main {
  display: grid;
  gap: 16px;
  min-width: 0;
}

.metric-grid,
.report-grid {
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
}

.metric-grid article,
.report-grid article {
  padding: 16px;
}

.metric-grid strong,
.report-grid strong {
  display: block;
  font-size: 1.6rem;
  margin-bottom: 6px;
}

.table-wrap {
  overflow-x: auto;
}

table {
  border-collapse: collapse;
  min-width: 760px;
  width: 100%;
}

th,
td {
  border-bottom: 1px solid rgba(37, 32, 39, 0.08);
  padding: 10px;
  text-align: left;
  vertical-align: top;
}

.inline-form {
  display: contents;
}

.product-admin-grid {
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
}

.product-editor {
  padding: 14px;
}

.swatch {
  border: 3px solid #fff;
  border-radius: 50%;
  display: inline-block;
  height: 34px;
  width: 34px;
}

.settings-form {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
}

.settings-form .wide {
  grid-column: 1 / -1;
}

.check {
  align-items: center;
  flex-direction: row !important;
}

.check input {
  min-height: 18px;
  width: auto;
}

.footer {
  align-items: center;
  color: #6a606b;
  display: flex;
  flex-wrap: wrap;
  font-size: 0.9rem;
  gap: 10px;
  justify-content: space-between;
  padding: 24px clamp(16px, 5vw, 70px);
}

@media (max-width: 980px) {
  .hero,
  .builder-shell,
  .admin-layout {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
    padding-bottom: 20px;
  }

  .hero-visual {
    min-height: 290px;
  }

  .desktop-categories {
    display: none;
  }

  .summary-panel,
  .admin-sidebar {
    position: static;
  }

  .builder-shell {
    padding-bottom: 86px;
  }

  .mobile-bottom {
    align-items: center;
    background: rgba(255, 255, 255, 0.96);
    border-top: 1px solid rgba(37, 32, 39, 0.08);
    bottom: 0;
    display: grid;
    gap: 8px;
    grid-template-columns: 92px 1fr 112px;
    left: 0;
    padding: 10px 12px;
    position: fixed;
    right: 0;
    z-index: 30;
  }
}

@media (max-width: 640px) {
  .topbar {
    gap: 12px;
  }

  .brand span:last-child {
    max-width: 150px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .topbar nav a {
    padding: 8px;
  }

  .hero {
    gap: 18px;
    padding: 24px 16px 12px;
  }

  .hero h1 {
    font-size: clamp(2.3rem, 14vw, 4rem);
  }

  .hero-actions .btn {
    width: 100%;
  }

  .category-strip,
  .content-band,
  .panel,
  .builder-shell,
  .admin-layout {
    padding-left: 12px;
    padding-right: 12px;
  }

  .bouquet-preview {
    grid-template-columns: 1fr;
  }

  .choice-card {
    grid-template-columns: 58px minmax(0, 1fr);
  }

  .settings-form {
    grid-template-columns: 1fr;
  }
}

.product-photo,
.admin-product-photo {
  background: #fff;
  border: 1px solid rgba(37, 32, 39, 0.08);
  border-radius: 8px;
  display: block;
  object-fit: cover;
}

.product-photo {
  aspect-ratio: 1 / 1;
  margin-bottom: 14px;
  width: 100%;
}

.product-photo.compact {
  height: 64px;
  margin: 0;
  width: 64px;
}

.admin-product-photo {
  aspect-ratio: 4 / 3;
  margin-bottom: 10px;
  width: 100%;
}

.choice-card .product-photo.compact {
  grid-row: span 1;
}

.store-card .product-photo + h3 {
  margin-top: 0;
}

.demo-inline-form {
  display: inline-flex;
  margin: 0;
}

.demo-access-card {
  margin-top: 14px;
}

.create-product-form {
  background: color-mix(in srgb, var(--secondary) 8%, #fff);
  border: 1px solid rgba(37, 32, 39, 0.08);
  border-radius: 8px;
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  margin-bottom: 18px;
  padding: 16px;
}

.create-product-form h3,
.create-product-form .btn {
  align-self: end;
}

.create-product-form h3 {
  margin: 0;
}

.module-grid,
.delivery-grid,
.settings-summary-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  margin-top: 18px;
}

.module-grid a,
.module-grid article,
.delivery-grid article,
.settings-summary-grid article {
  background: rgba(255, 255, 255, 0.84);
  border: 1px solid rgba(37, 32, 39, 0.08);
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 14px;
}

.module-grid strong,
.delivery-grid strong,
.settings-summary-grid strong {
  color: #231b24;
}

.module-grid span,
.delivery-grid span,
.settings-summary-grid span {
  color: #5f5560;
  line-height: 1.45;
}

.module-grid.compact {
  margin-top: 0;
}

@media (max-width: 640px) {
  .demo-inline-form,
  .demo-inline-form .btn {
    width: 100%;
  }

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