:root {
  color-scheme: light;
  --orange: #FF6B00;
  --orange-light: #FFF3E8;
  --bg: #f5f5f5;
  --card: #ffffff;
  --bg-elevated: #ffffff;
  --bg-soft: #FFF3E8;
  --text: #1a1a1a;
  --text-muted: #666666;
  --border: #e8e8e8;
  --radius: 12px;
  --shadow: 0 2px 8px rgba(0,0,0,0.08);
  --shadow-hover: 0 8px 24px rgba(0,0,0,0.12);
  --primary: #FF6B00;
  --primary-dark: #e65f00;
  --accent: #FF6B00;
  --success: #1f8f5f;
  --warning: #d97706;
  --danger: #d64545;
  --shadow-sm: 0 10px 30px rgba(23, 32, 51, 0.08);
  --shadow-md: 0 18px 40px rgba(23, 32, 51, 0.12);
  --nav-bg: rgba(255, 255, 255, 0.88);
  --footer-bg: #111827;
  --hero-start: #0f4cdb;
  --hero-end: #0ea5a4;
  --sidebar-bg: #111827;
  --sidebar-text: #cad4e3;
  --sidebar-active: #1f5eff;
}

[data-theme="dark"] {
  color-scheme: dark;
  --orange-light: #2a1710;
  --bg: #101112;
  --card: #181a1d;
  --bg-elevated: #1d2024;
  --bg-soft: #171d1f;
  --text: #f2f4f7;
  --text-muted: #a9b0ba;
  --border: #30343a;
  --primary: #FF6B00;
  --primary-dark: #ff8a33;
  --accent: #FF6B00;
  --success: #4fcb88;
  --warning: #f2b24d;
  --danger: #ff7a7a;
  --shadow-sm: 0 14px 34px rgba(0, 0, 0, 0.28);
  --shadow-md: 0 22px 48px rgba(0, 0, 0, 0.36);
  --nav-bg: rgba(12, 19, 32, 0.9);
  --footer-bg: #09111d;
  --hero-start: #10274d;
  --hero-end: #10384a;
}

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

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at top, rgba(31, 94, 255, 0.08), transparent 28%),
    linear-gradient(180deg, var(--bg-soft) 0%, var(--bg) 180px, var(--bg) 100%);
  color: var(--text);
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  transition: background-color 0.2s ease, color 0.2s ease;
}

a {
  color: var(--primary);
}

a:hover {
  color: var(--primary-dark);
}

h1, h2, h3, h4, h5, h6,
p, span, label, li, td, th, div {
  color: inherit;
}

.text-muted {
  color: var(--text-muted) !important;
}

.site-navbar.navbar {
  background: var(--nav-bg) !important;
  border-bottom: 1px solid rgba(127, 148, 182, 0.16);
  backdrop-filter: blur(14px);
}

.site-navbar .navbar-brand,
.site-navbar .nav-link {
  color: var(--text) !important;
}

.site-navbar .navbar-brand {
  letter-spacing: -0.02em;
}

.site-navbar .nav-link {
  border-radius: 999px;
  font-weight: 500;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.site-navbar .nav-link:hover,
.site-navbar .nav-link:focus {
  background: rgba(31, 94, 255, 0.08);
  color: var(--primary) !important;
}

.site-navbar .navbar-toggler {
  color: var(--text);
}

.theme-toggle {
  width: 40px;
  height: 40px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--bg-elevated);
  color: var(--text);
  font-size: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22);
}

.theme-toggle:hover {
  background: var(--bg-soft);
}

.card,
.modal-content,
.dropdown-menu,
.list-group-item,
.accordion-item {
  background-color: var(--bg-elevated) !important;
  color: var(--text) !important;
  border-color: var(--border) !important;
}

.card {
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: var(--shadow-sm);
}

.card-header,
.card-footer,
.table-light,
.list-group-item.active {
  background-color: var(--bg-soft) !important;
  color: var(--text) !important;
  border-color: var(--border) !important;
}

.table {
  color: var(--text);
}

.table > :not(caption) > * > * {
  border-bottom-color: var(--border);
  background-color: transparent;
}

.badge-instock,
.avail-yes {
  background: rgba(31, 143, 95, 0.14) !important;
  color: var(--success) !important;
}

.badge-nostock,
.avail-no {
  background: rgba(214, 69, 69, 0.12) !important;
  color: var(--danger) !important;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  border-color: transparent;
}

.btn-primary:hover,
.btn-primary:focus {
  background: linear-gradient(135deg, var(--primary-dark), var(--primary-dark));
  border-color: transparent;
}

.btn-outline-primary {
  color: var(--primary);
  border-color: rgba(31, 94, 255, 0.28);
}

.btn-outline-primary:hover,
.btn-outline-primary:focus {
  background: rgba(31, 94, 255, 0.08);
  color: var(--primary-dark);
  border-color: rgba(31, 94, 255, 0.5);
}

.btn-outline-secondary {
  color: var(--text-muted);
  border-color: var(--border);
}

.btn-outline-secondary:hover,
.btn-outline-secondary:focus {
  background: var(--bg-soft);
  color: var(--text);
  border-color: var(--border);
}

.btn-outline-light {
  color: var(--text);
  border-color: var(--border);
  background: transparent;
}

.btn-outline-light:hover,
.btn-outline-light:focus {
  background: var(--bg-soft);
  color: var(--text);
  border-color: var(--border);
}

.form-control,
.form-select,
.input-group-text {
  background-color: var(--bg-elevated) !important;
  color: var(--text) !important;
  border-color: var(--border) !important;
}

.form-control::placeholder {
  color: var(--text-muted);
}

.form-control:focus,
.form-select:focus {
  border-color: rgba(31, 94, 255, 0.4) !important;
  box-shadow: 0 0 0 0.2rem rgba(31, 94, 255, 0.14) !important;
}

.alert-info {
  background: rgba(31, 94, 255, 0.1);
  border-color: rgba(31, 94, 255, 0.14);
  color: var(--text);
}

.breadcrumb {
  padding: 0.75rem 1rem;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--bg-elevated);
  box-shadow: var(--shadow-sm);
}

.breadcrumb-item,
.breadcrumb-item a {
  color: var(--text-muted);
  text-decoration: none;
}

.breadcrumb-item.active {
  color: var(--text);
}

.hero-section {
  background: linear-gradient(135deg, var(--hero-start) 0%, #1f5eff 55%, var(--hero-end) 100%);
  box-shadow: inset 0 -1px 0 rgba(255, 255, 255, 0.08);
}

.calc-shell {
  border-radius: 28px !important;
}

.material-row {
  background: linear-gradient(180deg, rgba(31, 94, 255, 0.04), rgba(14, 165, 164, 0.02));
}

.calc-label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.35rem;
}

.quantity-stepper {
  display: grid;
  grid-template-columns: 52px 1fr 52px;
  gap: 0.75rem;
  align-items: center;
}

.quantity-stepper .btn,
.quantity-stepper .form-control {
  height: 52px;
  border-radius: 16px;
}

.calc-total-card {
  border: 1px solid var(--border);
  background: linear-gradient(180deg, rgba(31, 143, 95, 0.08), rgba(31, 94, 255, 0.04));
  border-radius: 20px;
  padding: 1rem 1.1rem;
}

.calc-total-price {
  font-size: 2rem;
  line-height: 1;
  font-weight: 800;
  color: var(--success);
  margin-bottom: 0.5rem;
}

.calc-hint {
  height: 100%;
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--bg-elevated);
}

.category-card,
.product-card,
.blog-card {
  border-radius: 20px !important;
}

.product-specs {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(132px, 1fr));
  gap: 0.75rem;
}

.product-spec {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.15rem 0.55rem;
  align-items: center;
  padding: 0.75rem 0.85rem;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--bg-elevated);
}

.product-spec i {
  grid-row: span 2;
  color: var(--primary);
  font-size: 1.15rem;
}

.product-spec span,
.catalog-specs {
  color: var(--text-muted);
}

.product-spec strong {
  font-size: 1rem;
}

.catalog-specs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.7rem;
  min-height: 1.25rem;
}

.category-card:hover,
.product-card:hover,
.blog-card:hover {
  box-shadow: var(--shadow-md) !important;
}

.site-footer {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(255, 255, 255, 0)), var(--footer-bg) !important;
}

.site-footer .text-muted,
.site-footer a.text-muted {
  color: rgba(220, 229, 244, 0.72) !important;
}

.site-footer a.text-muted:hover {
  color: #ffffff !important;
}

.login-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--hero-start) 0%, #16317a 52%, var(--hero-end) 100%);
}

.login-card {
  background: var(--bg-elevated);
  border-radius: 20px;
  box-shadow: var(--shadow-md);
  padding: 48px 40px;
  width: 100%;
  max-width: 420px;
  text-align: center;
}

.admin-wrapper {
  display: flex;
  min-height: 100vh;
}

.sidebar {
  width: 250px;
  background: var(--sidebar-bg);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  overflow-y: auto;
  z-index: 100;
  transition: width 0.25s;
}

.sidebar-brand {
  padding: 20px 18px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar-brand .brand-icon {
  font-size: 24px;
}

.sidebar-brand .brand-name {
  font-size: 16px;
  font-weight: 700;
  color: #fff;
  display: block;
}

.sidebar-brand .brand-sub {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.4);
}

.sidebar-nav {
  padding: 12px 0;
  flex: 1;
}

.nav-section {
  padding: 6px 18px 4px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.25);
  text-transform: uppercase;
  margin-top: 8px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px;
  color: var(--sidebar-text);
  text-decoration: none;
  border-radius: 0;
  transition: background 0.15s, color 0.15s;
  font-size: 13.5px;
  border-left: 3px solid transparent;
}

.nav-item:hover {
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
}

.nav-item.active {
  background: rgba(31, 94, 255, 0.3);
  color: #fff;
  border-left-color: var(--sidebar-active);
  font-weight: 600;
}

.main-content {
  margin-left: 250px;
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

@media (max-width: 991.98px) {
  .site-navbar .navbar-collapse {
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--border);
  }
}

@media (max-width: 768px) {
  .sidebar {
    width: 0;
    overflow: hidden;
  }

  .main-content {
    margin-left: 0;
  }
}

/* PrintParadise public theme */
body {
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", "Segoe UI", sans-serif;
  font-size: 15px;
  letter-spacing: 0;
}

a {
  color: var(--text);
}

a:hover {
  color: var(--orange);
}

.site-navbar.navbar {
  background: transparent !important;
  border: 0;
  box-shadow: none !important;
  padding: 18px 0 10px;
  position: sticky;
  top: 0;
  z-index: 1030;
}

.site-navbar-shell {
  max-width: 1180px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: var(--shadow);
  padding: 10px 16px;
}

.site-navbar .navbar-brand {
  font-size: 18px;
  color: var(--text) !important;
}

.brand-mark {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--orange-light);
  color: var(--orange);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.site-navbar .nav-item {
  display: block;
  padding: 0;
  border-left: 0;
  background: transparent;
}

.site-navbar .nav-link {
  border-radius: 8px;
  color: var(--text-muted) !important;
  font-weight: 600;
  font-size: 14px;
}

.site-navbar .nav-link:hover,
.site-navbar .nav-link:focus {
  background: var(--orange-light);
  color: var(--orange) !important;
}

.nav-icon-btn,
.theme-toggle,
.btn-ghost {
  height: 40px;
  min-width: 40px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--card);
  color: var(--text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-weight: 700;
}

.btn-ghost {
  padding: 0 14px;
}

.nav-icon-btn:hover,
.theme-toggle:hover,
.btn-ghost:hover {
  border-color: var(--orange);
  color: var(--orange);
  background: var(--orange-light);
}

.cart-count {
  position: absolute;
  top: -8px;
  right: -8px;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--orange);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 800;
}

.btn-orange,
.btn-primary {
  background: var(--orange) !important;
  border-color: var(--orange) !important;
  color: #fff !important;
  border-radius: 8px;
  font-weight: 800;
}

.btn-orange:hover,
.btn-primary:hover {
  background: #e65f00 !important;
  border-color: #e65f00 !important;
  color: #fff !important;
}

.btn-outline-primary {
  color: var(--text);
  border-color: var(--border);
  border-radius: 8px;
  font-weight: 700;
}

.btn-outline-primary:hover {
  color: var(--orange);
  border-color: var(--orange);
  background: var(--orange-light);
}

.card,
.pp-card,
.product-card,
.category-card {
  background: var(--card) !important;
  border: 1px solid var(--border) !important;
  border-radius: var(--radius) !important;
  box-shadow: var(--shadow) !important;
}

.card:hover,
.pp-card:hover,
.product-card:hover,
.category-card:hover {
  box-shadow: var(--shadow-hover) !important;
}

.pp-section {
  padding: 84px 0;
}

.pp-section-title {
  font-size: clamp(32px, 5vw, 48px);
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0;
  margin: 0;
}

.pp-section-lead {
  color: var(--text-muted);
  max-width: 620px;
  margin: 12px 0 0;
}

.pp-hero {
  min-height: 90vh;
  background: var(--bg);
  display: flex;
  align-items: center;
  padding: 54px 0 40px;
}

.pp-hero-grid {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(320px, 1fr);
  gap: 56px;
  align-items: center;
}

.pp-printer-stage {
  min-height: 420px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.pp-printer {
  width: min(430px, 100%);
  aspect-ratio: 1;
  border-radius: 28px;
  background: var(--card);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-hover);
  display: grid;
  place-items: center;
  position: relative;
}

.pp-printer::before {
  content: "";
  width: 62%;
  height: 62%;
  border: 16px solid var(--text);
  border-bottom-width: 28px;
  border-radius: 18px;
  display: block;
}

.pp-printer::after {
  content: "";
  position: absolute;
  width: 96px;
  height: 96px;
  border-radius: 22px;
  background: var(--orange);
  bottom: 72px;
  box-shadow: 0 18px 32px rgba(255, 107, 0, .28);
}

.pp-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: var(--orange-light);
  color: var(--orange);
  border-radius: 999px;
  font-weight: 800;
  margin-bottom: 20px;
}

.pp-hero h1 {
  font-size: clamp(42px, 6vw, 56px);
  line-height: 1;
  letter-spacing: 0;
  font-weight: 900;
  margin-bottom: 20px;
}

.pp-hero p {
  color: var(--text-muted);
  font-size: 18px;
  max-width: 560px;
}

.pp-product-grid,
.pp-category-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px;
}

.pp-category-card {
  padding: 24px;
  min-height: 188px;
  text-decoration: none;
  color: var(--text);
}

.pp-category-icon {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: var(--orange-light);
  color: var(--orange);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  margin-bottom: 22px;
}

.pp-product-card {
  overflow: hidden;
  height: 100%;
}

.pp-product-media {
  aspect-ratio: 1 / 1;
  background: #efefef;
  position: relative;
  overflow: hidden;
}

.pp-product-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.pp-product-placeholder {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  color: var(--text-muted);
  font-size: 44px;
}

.pp-material-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 6px 10px;
  border-radius: 999px;
  background: #1a1a1a;
  color: #fff;
  font-size: 12px;
  font-weight: 800;
}

.pp-product-body {
  padding: 16px;
}

.pp-product-title {
  font-weight: 800;
  text-decoration: none;
  color: var(--text);
  display: block;
  margin-bottom: 6px;
}

.pp-product-desc {
  color: var(--text-muted);
  font-size: 14px;
  min-height: 42px;
  margin-bottom: 14px;
}

.pp-product-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.pp-price {
  font-size: 20px;
  font-weight: 900;
}

.pp-add-btn {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  font-weight: 900;
}

.pp-add-btn:hover {
  border-color: var(--orange);
  background: var(--orange);
  color: #fff;
}

.shop-page {
  padding: 56px 0 80px;
}

.shop-tabs {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 8px 0 24px;
}

.shop-tab {
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--text-muted);
  border-radius: 999px;
  padding: 10px 18px;
  font-weight: 800;
  white-space: nowrap;
  text-decoration: none;
}

.shop-tab.active,
.shop-tab:hover {
  background: var(--text);
  border-color: var(--text);
  color: var(--card);
}

.floating-calc-btn {
  position: fixed;
  right: 26px;
  bottom: 26px;
  z-index: 1040;
  border: 0;
  border-radius: 999px;
  background: var(--orange);
  color: #fff;
  box-shadow: 0 12px 32px rgba(255, 107, 0, .32);
  padding: 14px 18px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
}

.print-calc-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, .52);
  z-index: 1050;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.print-calc-overlay.open {
  display: flex;
}

.modal-open-lite {
  overflow: hidden;
}

.print-calc-modal {
  width: min(860px, 100%);
  max-height: min(92vh, 860px);
  overflow: auto;
  background: var(--card);
  color: var(--text);
  border-radius: 16px;
  box-shadow: 0 24px 80px rgba(0,0,0,.28);
  padding: 28px;
  position: relative;
}

.print-calc-close {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 40px;
  height: 40px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--text);
}

.calc-modal-head {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: flex-start;
  margin-bottom: 24px;
}

.eyebrow {
  color: var(--orange);
  font-weight: 900;
  text-transform: uppercase;
  font-size: 12px;
  margin-bottom: 8px;
}

.calc-modal-head h2 {
  font-size: 34px;
  font-weight: 900;
  margin: 0;
}

.calc-total-pill {
  background: var(--orange);
  color: #fff;
  border-radius: 12px;
  padding: 12px 16px;
  font-size: 22px;
  font-weight: 900;
  white-space: nowrap;
}

.calc-step {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 18px;
  margin-bottom: 16px;
}

.calc-step-title {
  font-weight: 900;
  margin-bottom: 14px;
}

.material-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.material-tab {
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--text);
  border-radius: 8px;
  padding: 10px 16px;
  font-weight: 900;
}

.material-tab.active {
  background: var(--orange);
  color: #fff;
  border-color: var(--orange);
}

.material-table {
  display: grid;
  gap: 8px;
}

.material-row-choice {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr auto 2fr;
  gap: 14px;
  align-items: center;
  text-align: left;
  border: 1px solid var(--border);
  background: var(--card);
  border-radius: 10px;
  padding: 12px;
}

.material-row-choice.active {
  border-color: var(--orange);
  background: var(--orange-light);
}

.material-row-choice b {
  color: var(--orange);
}

.material-row-choice em {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  font-style: normal;
}

.material-row-choice em span {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 4px 8px;
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 700;
}

.calc-param-grid {
  display: grid;
  grid-template-columns: 1fr 140px 190px;
  gap: 16px;
  align-items: end;
}

.range-labels {
  display: flex;
  justify-content: space-between;
  color: var(--text-muted);
  font-size: 12px;
}

.quantity-stepper.compact {
  grid-template-columns: 44px 1fr 44px;
  gap: 8px;
}

.calc-summary {
  display: grid;
  grid-template-columns: 1fr 240px;
  gap: 18px;
  align-items: center;
  background: var(--orange-light);
  border-radius: 12px;
  padding: 18px;
}

.calc-summary-price {
  font-size: 34px;
  font-weight: 900;
  color: var(--orange);
}

.calculator-page {
  padding: 70px 0 90px;
}

.calculator-panel {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 24px;
  align-items: start;
}

@media (max-width: 991.98px) {
  .site-navbar-shell {
    margin: 0 12px;
  }
  .site-navbar .navbar-collapse {
    margin-top: 12px;
    padding-top: 12px;
  }
  .pp-hero-grid,
  .calculator-panel {
    grid-template-columns: 1fr;
  }
  .pp-category-grid,
  .pp-product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .calc-param-grid,
  .calc-summary {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 575.98px) {
  .pp-hero {
    min-height: auto;
    padding-top: 32px;
  }
  .pp-printer-stage {
    min-height: 260px;
  }
  .pp-category-grid,
  .pp-product-grid {
    grid-template-columns: 1fr;
  }
  .floating-calc-btn {
    right: 16px;
    bottom: 16px;
    padding: 12px 14px;
  }
  .print-calc-modal {
    padding: 22px 16px;
  }
  .material-row-choice {
    grid-template-columns: 1fr;
  }
}

/* Public finish pass */
html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main,
.container.py-4,
.container.py-5 {
  flex: 1 0 auto;
}

[data-theme="dark"] body {
  background:
    linear-gradient(180deg, rgba(255, 107, 0, 0.08), transparent 220px),
    var(--bg);
}

[data-theme="dark"] .site-navbar-shell,
[data-theme="dark"] .print-calc-modal,
[data-theme="dark"] .pp-printer,
[data-theme="dark"] .pp-card,
[data-theme="dark"] .card,
[data-theme="dark"] .dropdown-menu {
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.34) !important;
}

[data-theme="dark"] .navbar-toggler-icon {
  filter: invert(1) grayscale(1);
}

[data-theme="dark"] .bg-white,
[data-theme="dark"] .bg-light,
[data-theme="dark"] .alert-light,
[data-theme="dark"] .text-bg-light {
  background-color: var(--bg-elevated) !important;
  color: var(--text) !important;
  border-color: var(--border) !important;
}

[data-theme="dark"] .text-dark {
  color: var(--text) !important;
}

[data-theme="dark"] .dropdown-item {
  color: var(--text) !important;
}

[data-theme="dark"] .dropdown-item:hover,
[data-theme="dark"] .dropdown-item:focus {
  background: var(--bg-soft) !important;
  color: var(--orange) !important;
}

.container.py-4,
.container.py-5 {
  width: min(100% - 24px, 1180px);
  padding-top: 56px !important;
  padding-bottom: 80px !important;
}

.container.py-4 > h2,
.container.py-5 > h2,
.container.py-5 h2.fw-bold:first-child {
  font-size: clamp(30px, 4vw, 44px);
  line-height: 1;
  letter-spacing: 0;
  font-weight: 900 !important;
}

.breadcrumb {
  border-radius: 8px;
  box-shadow: none;
}

.table-responsive {
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--card);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.table {
  margin-bottom: 0;
}

.table thead th {
  color: var(--text-muted);
  font-size: 12px;
  text-transform: uppercase;
  font-weight: 900;
}

.table td,
.table th {
  padding: 16px;
  vertical-align: middle;
}

.table-light,
.card-header.bg-white {
  background: var(--bg-soft) !important;
}

.list-group-item {
  background: var(--card) !important;
}

.alert {
  border-radius: 8px;
}

.alert-warning {
  background: rgba(242, 178, 77, 0.12);
  border-color: rgba(242, 178, 77, 0.2);
  color: var(--text);
}

.alert-danger {
  background: rgba(214, 69, 69, 0.12);
  border-color: rgba(214, 69, 69, 0.22);
  color: var(--text);
}

.form-control,
.form-select,
.btn {
  border-radius: 8px;
}

.form-control,
.form-select {
  min-height: 44px;
}

.form-text {
  color: var(--text-muted);
}

.badge {
  border-radius: 999px;
  font-weight: 800;
}

.bg-success {
  background-color: var(--success) !important;
}

.bg-secondary {
  background-color: var(--text-muted) !important;
}

.bg-danger {
  background-color: var(--danger) !important;
}

#mainMediaCard {
  overflow: hidden;
  min-height: 420px;
  display: grid;
  place-items: center;
}

#mainMediaCard img,
#mainMediaCard video {
  width: 100%;
  background: var(--bg-soft);
}

#mediaThumbs .btn {
  border-radius: 8px;
  background: var(--card);
}

#productTitle {
  font-size: clamp(32px, 4vw, 48px);
  line-height: 1.02;
  letter-spacing: 0;
  font-weight: 900 !important;
}

#productPriceBlock .display-6,
#productPriceBlock .fw-bold.display-6 {
  color: var(--orange) !important;
  font-weight: 900 !important;
}

.variant-btn {
  min-height: 40px;
  font-weight: 800;
}

.card.bg-body-tertiary,
.bg-body-tertiary {
  background: var(--bg-soft) !important;
  color: var(--text) !important;
}

.blog-card,
.blog-list-card {
  height: 100%;
  overflow: hidden;
}

.card-img-top {
  background: var(--bg-soft);
}

.checkout-choice,
.border.rounded.p-3 {
  border-color: var(--border) !important;
  border-radius: 12px !important;
  background: var(--card);
}

.site-footer {
  margin-top: auto;
  padding-top: 42px !important;
  padding-bottom: 32px !important;
}

.site-footer h5,
.site-footer h6 {
  color: #fff !important;
}

#contacts {
  scroll-margin-top: 120px;
}

.floating-calc-btn:hover {
  background: #e65f00;
  color: #fff;
}

@media (max-width: 767.98px) {
  .container.py-4,
  .container.py-5 {
    width: min(100% - 18px, 1180px);
    padding-top: 34px !important;
    padding-bottom: 64px !important;
  }

  .site-navbar-shell {
    border-radius: 12px;
  }

  .site-navbar .d-flex.align-items-center.gap-2.flex-wrap {
    align-items: stretch !important;
  }

  .site-navbar .btn-orange,
  .site-navbar .btn-ghost {
    flex: 1 1 auto;
  }

  .table-responsive {
    border-radius: 8px;
  }

  .table td,
  .table th {
    padding: 12px;
  }

  #mainMediaCard {
    min-height: 280px;
  }

  .d-flex.justify-content-between.mt-3 {
    flex-direction: column;
    gap: 12px;
  }

  .d-flex.justify-content-between.mt-3 > .d-flex {
    flex-direction: column;
  }
}
