/* TransMetal BIM — Ultra-Modern Minimal Theme */
:root {
  --header-height: 72px;
  --bg: #0A0A0A;
  --panel: rgba(20, 20, 20, 0.95);
  --panel2: rgba(26, 26, 26, 0.9);
  --card: #141414;
  --muted: #A3A3A3;
  --text: #FAFAFA;
  --accent: #818CF8;
  --accent2: #6366F1;
  --accent-glow: rgba(129, 140, 248, 0.12);
  --accent2-glow: rgba(99, 102, 241, 0.1);
  --danger: #F87171;
  --success: #34D399;
  --border: rgba(255, 255, 255, 0.06);
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  --radius: 16px;
  --radius2: 10px;
  --font: 'General Sans', -apple-system, system-ui, sans-serif;
  --font-display: 'Satoshi', 'General Sans', sans-serif;
  --mono: 'SF Mono', 'Menlo', monospace;
  --glow-sm: 0 1px 4px rgba(129, 140, 248, 0.1);
  --glow-md: 0 2px 12px rgba(129, 140, 248, 0.08);
  --glow-lg: 0 4px 24px rgba(129, 140, 248, 0.06);
  --header-bg: rgba(10, 10, 10, 0.85);
  --input-bg: rgba(255, 255, 255, 0.04);
  --logo-bg: transparent;
  --ghost-hover: rgba(255, 255, 255, 0.04);
  --btn-bg: rgba(255, 255, 255, 0.06);
  --btn-hover: rgba(255, 255, 255, 0.1);
  --btn-border-hover: rgba(255, 255, 255, 0.15);
  --btn-primary-text: #FFFFFF;
  --viz-area-bg: #0A0A0A;
  --viz-header-bg: rgba(10, 10, 10, 0.9);
  --viz-canvas-bg: #0A0A0A;
  --view-toggle-bg: rgba(255, 255, 255, 0.04);
  --sidebar-bg: rgba(10, 10, 10, 0.98);
  --params-header-bg: rgba(255, 255, 255, 0.03);
  --scrollbar-thumb: rgba(255, 255, 255, 0.1);
  --chip-bg: rgba(255, 255, 255, 0.04);
  --style-card-bg: rgba(255, 255, 255, 0.03);
  --style-card-border: rgba(255, 255, 255, 0.06);
  --dim-input-bg: rgba(255, 255, 255, 0.05);
  --dim-input-border: rgba(255, 255, 255, 0.1);
  --range-input-bg: rgba(255, 255, 255, 0.04);
  --text2: #D4D4D4;
  --range-track-bg: rgba(255, 255, 255, 0.08);
  --roof-card-bg: rgba(255, 255, 255, 0.03);
  --btn-border: rgba(255, 255, 255, 0.08);
  --ai-bubble-bg: rgba(129, 140, 248, 0.08);
  --hover: rgba(255, 255, 255, 0.04);
}

[data-theme="light"] {
  --bg: #FAFAFA;
  --panel: rgba(255, 255, 255, 0.95);
  --panel2: rgba(250, 250, 250, 0.9);
  --card: #FFFFFF;
  --muted: #737373;
  --text: #171717;
  --accent: #4F46E5;
  --accent2: #4338CA;
  --accent-glow: rgba(79, 70, 229, 0.08);
  --accent2-glow: rgba(67, 56, 202, 0.06);
  --border: rgba(0, 0, 0, 0.06);
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
  --glow-sm: 0 1px 4px rgba(79, 70, 229, 0.08);
  --glow-md: 0 2px 12px rgba(79, 70, 229, 0.06);
  --glow-lg: 0 4px 24px rgba(79, 70, 229, 0.04);
  --header-bg: rgba(250, 250, 250, 0.85);
  --input-bg: #FFFFFF;
  --logo-bg: transparent;
  --ghost-hover: rgba(0, 0, 0, 0.03);
  --btn-bg: #FFFFFF;
  --btn-hover: rgba(0, 0, 0, 0.04);
  --btn-border-hover: rgba(0, 0, 0, 0.12);
  --btn-primary-text: #FFFFFF;
  --viz-area-bg: #FAFAFA;
  --viz-header-bg: rgba(250, 250, 250, 0.9);
  --viz-canvas-bg: #F5F5F5;
  --view-toggle-bg: #FFFFFF;
  --sidebar-bg: rgba(255, 255, 255, 0.98);
  --params-header-bg: rgba(0, 0, 0, 0.02);
  --scrollbar-thumb: rgba(0, 0, 0, 0.1);
  --chip-bg: #FFFFFF;
  --style-card-bg: #FFFFFF;
  --style-card-border: rgba(0, 0, 0, 0.08);
  --dim-input-bg: #FFFFFF;
  --dim-input-border: rgba(0, 0, 0, 0.1);
  --range-input-bg: #FFFFFF;
  --text2: #525252;
  --range-track-bg: rgba(0, 0, 0, 0.08);
  --roof-card-bg: #FFFFFF;
  --btn-border: rgba(0, 0, 0, 0.08);
  --ai-bubble-bg: rgba(79, 70, 229, 0.06);
  --hover: rgba(0, 0, 0, 0.03);
}

* {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
  margin: 0;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.5;
}

.app-main {
  min-height: 0;
}

@media (min-width: 1101px) {
  body.is-configurator {
    overflow: hidden;
  }

  body.is-configurator .app-main {
    height: calc(100dvh - var(--header-height));
    overflow: hidden;
  }
}

.app-shell {
  position: relative;
  z-index: 1;
  min-height: 100%;
}

/* ═══════════ HEADER ═══════════ */
.header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--header-bg);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 28px;
  max-width: 1440px;
  margin: 0 auto;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
}

.brand h1 {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
  font-family: var(--font-display);
  letter-spacing: -0.3px;
}

.brand small {
  display: none;
}

.logo {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--logo-bg);
  display: grid;
  place-items: center;
  position: relative;
  overflow: hidden;
}

.logo::before {
  display: none;
}

.logo svg {
  width: 24px;
  height: 24px;
}

.nav {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* ═══════════ BUTTONS ═══════════ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid var(--btn-border);
  background: var(--btn-bg);
  color: var(--text);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: var(--font);
}

.btn:hover {
  background: var(--btn-hover);
  border-color: var(--btn-border-hover);
}

.btn.small {
  padding: 6px 12px;
  font-size: 12px;
}

.btn.primary {
  background: var(--accent);
  border: none;
  color: var(--btn-primary-text);
  font-weight: 600;
}

.btn.primary:hover {
  background: var(--accent2);
  transform: translateY(-1px);
}

.btn.primary:active {
  transform: translateY(0);
}

.btn.ghost {
  background: transparent;
  border-color: transparent;
}

.btn.ghost:hover {
  background: var(--ghost-hover);
}

.btn.danger {
  color: var(--danger);
  border-color: rgba(248, 113, 113, 0.2);
}

.btn.danger:hover {
  background: rgba(248, 113, 113, 0.08);
}

.btn.success {
  color: var(--success);
  border-color: rgba(52, 211, 153, 0.2);
}

/* ═══════════ PANELS & CARDS ═══════════ */
.panel {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.panel.pad {
  padding: 24px;
}

.card {
  background: var(--card);
  border: 1px solid transparent;
  border-radius: var(--radius2);
  padding: 16px;
  transition: border-color 0.2s, box-shadow 0.2s;
  box-shadow: var(--shadow);
}

.card:hover {
  border-color: var(--border);
}

.card h3 {
  margin: 0 0 8px;
  font-size: 14px;
  font-weight: 600;
  font-family: var(--font-display);
}

.card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

/* ═══════════ FORM ELEMENTS ═══════════ */
.field {
  display: grid;
  gap: 5px;
  margin-bottom: 14px;
}

.label {
  font-size: 11px;
  font-weight: 500;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.input,
.select {
  width: 100%;
  padding: 9px 12px;
  border-radius: var(--radius2);
  border: 1px solid var(--border);
  background: var(--input-bg);
  color: var(--text);
  font-size: 13px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.input:focus,
.select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px var(--accent-glow);
}

.hint {
  font-size: 10px;
  color: var(--muted);
}

/* ═══════════ RANGE SLIDER ═══════════ */
.range-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
}

.range-wrap input[type="range"] {
  flex: 1;
  -webkit-appearance: none;
  appearance: none;
  height: 4px;
  background: var(--range-track-bg);
  border-radius: 4px;
  outline: none;
}

.range-wrap input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 1px 4px rgba(37, 99, 235, 0.4);
  cursor: pointer;
}

.range-input {
  width: 54px;
  padding: 5px 8px;
  background: var(--range-input-bg);
  border: 1px solid var(--border);
  border-radius: 7px;
  text-align: center;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
  font-family: var(--mono);
}

.range-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 2px var(--accent-glow);
}

/* ═══════════ CHIPS ═══════════ */
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.chip {
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--chip-bg);
  color: var(--muted);
  font-size: 12px;
  cursor: pointer;
  transition: all 0.2s;
}

.chip:hover {
  border-color: var(--btn-border-hover);
  color: var(--text);
}

.chip.active {
  background: var(--accent-glow);
  color: var(--accent);
  border-color: var(--accent);
  font-weight: 600;
}

/* ═══════════ BADGE ═══════════ */
.badge {
  display: inline-flex;
  padding: 3px 8px;
  border-radius: 16px;
  font-size: 10px;
  font-weight: 500;
  background: rgba(22, 32, 52, 0.6);
  color: var(--muted);
  border: 1px solid var(--border);
}

.badge.accent {
  background: var(--accent-glow);
  color: var(--accent);
  border-color: rgba(0, 240, 255, 0.25);
}

/* ═══════════ GRID ═══════════ */
.grid2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

.grid3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

@media (max-width: 768px) {

  .grid2,
  .grid3 {
    grid-template-columns: 1fr;
  }
}

/* ═══════════ WORKSPACE LAYOUT ═══════════ */
.workspace {
  display: grid;
  grid-template-columns: 1fr 340px;
  height: 100%;
  min-height: 0;
  overflow: hidden;
}

@media (max-width: 1024px) {
  .workspace {
    grid-template-columns: 1fr;
    height: auto;
    overflow: visible;
  }
}

/* ═══════════ VISUALIZATION AREA ═══════════ */
.viz-area {
  background: var(--viz-area-bg);
  border-right: 1px solid var(--border);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.viz-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 12px;
  border-bottom: 1px solid var(--border);
  background: var(--viz-header-bg);
  flex-shrink: 0;
  backdrop-filter: blur(12px);
}

.viz-canvas {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--viz-canvas-bg);
  position: relative;
  overflow: hidden;
}

.viz-canvas canvas {
  width: 100% !important;
  height: 100% !important;
}

/* ═══════════ VIEW TOGGLE ═══════════ */
.view-toggle {
  display: flex;
  background: var(--view-toggle-bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 3px;
}

.view-toggle button {
  padding: 5px 12px;
  border: none;
  background: transparent;
  color: var(--muted);
  font-size: 11px;
  cursor: pointer;
  border-radius: 6px;
  transition: all 0.2s;
  font-weight: 500;
}

.view-toggle button.active {
  background: rgba(37, 99, 235, 0.15);
  color: var(--accent);
  font-weight: 600;
}

/* ═══════════ PARAMS SIDEBAR ═══════════ */
.params-sidebar {
  background: var(--sidebar-bg);
  border-left: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  height: 100%;
  backdrop-filter: blur(16px);
  width: 388px;
  flex: 0 0 388px;
}

.params-header {
  padding: 10px 16px;
  border-bottom: 1px solid var(--border);
  background: var(--params-header-bg);
  flex-shrink: 0;
}

.params-header h2 {
  margin: 0;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: var(--muted);
}

.params-body {
  flex: 1;
  overflow-y: auto;
  padding: 14px;
}

/* Scrollbar */
.params-body::-webkit-scrollbar {
  width: 4px;
}

.params-body::-webkit-scrollbar-track {
  background: transparent;
}

.params-body::-webkit-scrollbar-thumb {
  background: var(--scrollbar-thumb);
  border-radius: 4px;
}

.params-section {
  margin-bottom: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
}

.params-section:last-child {
  border-bottom: none;
  margin-bottom: 0;
}

.params-section h3 {
  margin: 0 0 12px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-family: var(--font-display);
}

/* ═══════════ COST BREAKDOWN ═══════════ */
.cost-breakdown {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
  justify-content: flex-end;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none; /* Firefox */
}
.cost-breakdown::-webkit-scrollbar {
  display: none; /* Chrome/Safari */
}

.cost-items {
  display: flex;
  gap: 0;
  flex-wrap: nowrap;
  background: var(--view-toggle-bg);
  border-radius: 8px;
  border: 1px solid var(--border);
  height: 38px;
}

.cost-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
  border-right: 1px solid var(--border);
  height: 100%;
}

.cost-item:last-child {
  border-right: none;
}

.cost-label {
  font-size: 9px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.4px;
  white-space: nowrap;
  margin-bottom: 2px;
}

.cost-value {
  font-size: 12px;
  font-weight: 700;
  color: var(--text2);
  font-family: var(--mono);
  white-space: nowrap;
  line-height: 1;
}

.cost-total.area-bubble {
  min-width: 90px;
}
.cost-total.area-bubble .cost-total-label,
.cost-total.area-bubble .cost-total-value {
  text-align: center;
}

.cost-totals {
  display: flex;
  align-items: stretch;
  gap: 6px;
  flex-shrink: 0;
}

.cost-total {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: center;
  padding: 0 14px;
  background: var(--accent-glow);
  border: 1px solid rgba(37, 99, 235, 0.2);
  border-radius: 8px;
  min-width: 120px;
  height: 38px;
  transition: all 0.2s;
}

.cost-total-label {
  font-size: 9px;
  font-weight: 600;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.4px;
  text-align: right;
  margin-bottom: 2px;
  opacity: 0.9;
}

.cost-total-value {
  font-size: 12px;
  font-weight: 800;
  color: var(--accent);
  font-family: var(--mono);
  line-height: 1;
  white-space: nowrap;
  text-align: right;
}

.cost-total-work {
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  border: none;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.2);
}

.cost-total-work .cost-total-label {
  color: rgba(255, 255, 255, 0.85);
}

.cost-total-work .cost-total-value {
  color: #ffffff;
}


/* ═══════════ VIZ OVERLAY CONTROLS ═══════════ */
.viz-canvas {
  position: relative;
}

.viz-controls-overlay {
  position: absolute;
  bottom: 16px;
  right: 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  z-index: 10;
}

.viz-ctrl-btn {
  width: 40px;
  height: 40px;
  border: 1px solid var(--border);
  border-radius: var(--radius2);
  background: var(--btn-bg);
  backdrop-filter: blur(8px);
  color: var(--accent);
  font-size: 20px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.viz-ctrl-btn:hover {
  background: var(--btn-hover);
  border-color: var(--accent);
  transform: scale(1.05);
}

.viz-ctrl-btn:active {
  transform: scale(0.95);
}

/* ═══════════ STYLE SELECTOR ═══════════ */
.style-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.style-card {
  border-radius: var(--radius2);
  border: 2px solid var(--style-card-border);
  overflow: hidden;
  cursor: pointer;
  transition: all 0.25s ease;
  position: relative;
  background: var(--style-card-bg);
}

.style-card:hover {
  border-color: rgba(37, 99, 235, 0.3);
  transform: translateY(-2px);
  box-shadow: var(--glow-sm);
}

.style-card.active {
  border-color: var(--accent);
  box-shadow: var(--glow-md);
}

.style-card.active::after {
  content: "✓";
  position: absolute;
  top: 4px;
  right: 4px;
  width: 20px;
  height: 20px;
  background: var(--accent);
  color: #000;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
}

.style-card img {
  width: 100%;
  height: 70px;
  object-fit: cover;
  display: block;
}

.style-name {
  padding: 5px;
  text-align: center;
  font-size: 10px;
  font-weight: 600;
  color: var(--text2);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* ═══════════ OPENING CARDS ═══════════ */
/* ═══════════ INTERACTIVE DIMENSIONS ═══════════ */
.dim-interactive {
  transition: all 0.2s;
}

/* Remove hover from lines */
.dim-interactive line {
  pointer-events: none;
}

/* Badge styling for values */
.dim-badge {
  cursor: pointer;
  fill: rgba(255, 255, 255, 0.9);
  stroke: rgba(148, 163, 184, 0.6);
  stroke-width: 0.8;
  rx: 4;
  transition: all 0.2s;
}

.dim-interactive:hover .dim-badge {
  fill: rgba(236, 244, 255, 0.94);
  stroke: rgba(63, 99, 246, 0.55);
  stroke-width: 1;
}

.dim-interactive:hover text {
  fill: #2f3b4a;
  font-weight: 600;
}

.dim-input-overlay {
  position: absolute;
  transform: translate(-50%, -50%);
  background: var(--dim-input-bg);
  border: 1px solid var(--accent);
  color: var(--text);
  padding: 4px 8px;
  border-radius: 4px;
  font-family: var(--font);
  font-size: 12px;
  font-weight: 600;
  width: 80px;
  text-align: center;
  box-shadow: var(--shadow);
  z-index: 100;
  outline: none;
}

/* Plan View Controls (Bottom) */
.plan-layout {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 10px 12px 14px;
}

.plan-stage {
  flex: 1;
  width: 100%;
  min-height: 0;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
  cursor: default;
}

.plan-stage.is-pannable {
  cursor: grab;
}

.plan-stage.is-dragging {
  cursor: grabbing;
}

.plan-stage.is-dragging,
.plan-stage.is-dragging * {
  user-select: none;
}

.plan-viewport-content {
  transform-origin: center center;
  transition: none;
}

.plan-svg {
  display: block;
}

.section-layout {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px 12px 14px;
}

.section-stage {
  width: 100%;
  height: 100%;
  min-height: 0;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
  cursor: default;
}

.section-stage.is-pannable {
  cursor: grab;
}

.section-stage.is-dragging {
  cursor: grabbing;
}

.section-stage.is-dragging,
.section-stage.is-dragging * {
  user-select: none;
}

.section-viewport-content {
  transform-origin: center center;
  transition: none;
}

.section-svg {
  display: block;
}

.plan-controls {
  display: inline-flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 0;
  padding: 8px 14px;
  background: var(--panel2);
  border-radius: 12px;
  border: 1px solid var(--border);
}

.plan-control-label {
  display: flex;
  flex-direction: row;
  align-items: baseline;
  gap: 4px;
  line-height: 1.05;
  font-size: 10px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.plan-control-label small {
  margin-top: 0;
  font-size: 10px;
  letter-spacing: 0.02em;
  font-weight: 600;
}

.plan-step-input {
  width: 84px;
  height: 32px;
  text-align: center;
  padding: 0 8px;
  font-size: 14px;
  font-weight: 600;
}

.opening-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  border-radius: var(--radius2);
  padding: 10px;
}

.opening-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}

.opening-title {
  font-size: 12px;
  font-weight: 600;
  color: var(--text2);
}

.opening-wall {
  font-size: 10px;
  color: var(--accent);
  background: var(--accent-glow);
  border: 1px solid rgba(37, 99, 235, 0.2);
  border-radius: 4px;
  padding: 1px 6px;
  margin-left: auto;
}

.opening-dims {
  display: flex;
  gap: 10px;
}

.dim-field {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  color: var(--muted);
}

.dim-label {
  font-size: 9px;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
}

.dim-input {
  width: 64px;
  padding: 3px 6px;
  background: var(--dim-input-bg);
  border: 1px solid var(--dim-input-border);
  border-radius: 4px;
  color: var(--text2);
  font-size: 12px;
  font-family: var(--mono);
}

.dim-input:focus {
  border-color: var(--accent);
  outline: none;
  box-shadow: 0 0 0 2px var(--accent-glow);
}

/* ═══════════ PLACEMENT MODE ═══════════ */
.placement-dimmer {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 50;
  pointer-events: none;
  animation: dimmerFadeIn 0.3s ease;
}

@keyframes dimmerFadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

.placement-banner {
  position: absolute;
  top: 12px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 20px;
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid rgba(37, 99, 235, 0.4);
  border-radius: 12px;
  backdrop-filter: blur(12px);
  z-index: 60;
  color: #fff;
  font-size: 13px;
  box-shadow: var(--glow-md);
  animation: bannerSlideIn 0.3s ease;
}

@keyframes bannerSlideIn {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(-10px);
  }

  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

.placement-icon {
  font-size: 18px;
}

.placement-banner strong {
  color: var(--accent);
}

/* Ensure viz-canvas is above dimmer */
.viz-canvas {
  z-index: 55;
}

/* ═══════════ MODAL ═══════════ */
.modal-back {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 100;
  backdrop-filter: blur(8px);
}

.modal-back.show {
  display: flex;
}

.modal {
  width: 100%;
  max-width: 440px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.6);
  overflow: hidden;
  backdrop-filter: blur(20px);
}

.modal .mhead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
}

.modal .mhead strong {
  font-size: 14px;
}

.modal .mbody {
  padding: 18px;
}

.modal .mfoot {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
  padding: 14px 16px;
  border-top: 1px solid var(--border);
}

/* Auth Tabs */
.auth-tabs {
  display: flex;
  gap: 6px;
  margin-bottom: 14px;
}

.auth-tabs button {
  flex: 1;
  padding: 8px;
  border: 1px solid var(--border);
  border-radius: var(--radius2);
  background: var(--chip-bg);
  color: var(--muted);
  cursor: pointer;
  font-size: 12px;
  transition: all 0.2s;
}

.auth-tabs button.active {
  background: var(--accent-glow);
  border-color: rgba(37, 99, 235, 0.3);
  color: var(--accent);
}

/* ═══════════ TOAST ═══════════ */
.toast {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--panel);
  border: 1px solid rgba(37, 99, 235, 0.3);
  color: var(--text);
  padding: 10px 18px;
  border-radius: var(--radius2);
  box-shadow: var(--shadow);
  z-index: 150;
  font-size: 12px;
  backdrop-filter: blur(12px);
}

/* ═══════════ BURGER / DRAWER ═══════════ */
.burger {
  display: none;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--btn-bg);
  cursor: pointer;
  align-items: center;
  justify-content: center;
}

@media (max-width: 768px) {
  .nav {
    display: none;
  }

  .burger {
    display: flex;
  }
}

.drawer-back {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 80;
  display: none;
}

.drawer {
  position: absolute;
  right: 12px;
  top: 12px;
  width: min(300px, calc(100% - 24px));
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(20px);
}

.drawer .dhead {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
}

.drawer .dlinks {
  display: grid;
  gap: 6px;
}

.drawer .dlinks .btn {
  justify-content: flex-start;
}

/* ═══════════ FOOTER ═══════════ */
.footer {
  padding: 20px 24px;
  border-top: 1px solid var(--border);
  margin-top: 40px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  color: var(--muted);
  font-size: 12px;
}

.link {
  color: var(--muted);
  text-decoration: none;
}

.link:hover {
  color: var(--accent);
}

/* ═══════════ HERO / LANDING ═══════════ */
.hero {
  text-align: center;
  padding: 100px 20px 60px;
}

.hero h1 {
  font-size: 52px;
  font-weight: 900;
  margin: 0 0 20px;
  line-height: 1.05;
  letter-spacing: -1.5px;
  font-family: var(--font-display);
}

.hero h1 .accent {
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero p {
  font-size: 18px;
  color: var(--muted);
  max-width: 520px;
  margin: 0 auto 36px;
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

/* Samples Grid */
.samples-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 36px;
}

@media (max-width: 900px) {
  .samples-grid {
    grid-template-columns: 1fr;
  }
}

.sample-card {
  background: var(--card);
  border: 1px solid transparent;
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.3s, box-shadow 0.3s, border-color 0.3s;
  box-shadow: var(--shadow);
}

.sample-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--glow-md);
  border-color: var(--border);
}

.sample-card .img {
  height: 180px;
  background: var(--card);
  display: grid;
  place-items: center;
  color: var(--muted);
}

.sample-card .body {
  padding: 16px;
}

.sample-card h3 {
  margin: 0 0 8px;
  font-size: 15px;
  font-family: var(--font-display);
  font-weight: 600;
}

.sample-card p {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
}

/* ═══════════ THEME TOGGLE ═══════════ */
.theme-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: 16px;
  background: var(--chip-bg);
  border: 1px solid var(--border);
  cursor: pointer;
  font-size: 11px;
  color: var(--muted);
  transition: all 0.2s;
}

.theme-toggle:hover {
  border-color: rgba(37, 99, 235, 0.2);
}

/* ═══════════ COLOR SWATCH ═══════════ */
.color-swatch {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  border: 2px solid rgba(255, 255, 255, 0.08);
  cursor: pointer;
  transition: all 0.2s;
}

.color-swatch:hover {
  transform: scale(1.12);
  border-color: rgba(255, 255, 255, 0.2);
}

.color-swatch.active {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px var(--accent-glow), var(--glow-sm);
}

.color-grid {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 6px;
}

@media (max-width: 480px) {
  .color-grid {
    grid-template-columns: repeat(5, 1fr);
  }
}

/* ═══════════ ROOF TYPE CARDS ═══════════ */
.roof-types {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.roof-card {
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius2);
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  background: var(--roof-card-bg);
  border: 1px solid var(--btn-border);
}

.roof-card:hover {
  border-color: rgba(37, 99, 235, 0.25);
  background: rgba(37, 99, 235, 0.04);
}

.roof-card.active {
  border-color: rgba(37, 99, 235, 0.4);
  background: rgba(37, 99, 235, 0.08);
}

.roof-card .icon {
  width: 48px;
  height: 36px;
  margin: 0 auto 6px;
  background: none;
  border-radius: 4px;
}

.roof-card .icon svg {
  width: 100%;
  height: 100%;
}

.roof-card .name {
  font-size: 11px;
  font-weight: 500;
  color: var(--muted);
}

.roof-card.active .name {
  color: var(--accent);
}

.roof-card.is-disabled {
  opacity: 0.5;
  cursor: not-allowed;
  border-style: dashed;
}

.roof-card.is-disabled:hover {
  border-color: var(--btn-border);
  background: var(--roof-card-bg);
}

/* ═══════════ OPENINGS ═══════════ */
.sides-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.side-check {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius2);
  cursor: pointer;
  font-size: 12px;
  transition: all 0.2s;
}

.side-check input {
  accent-color: var(--accent);
  width: 16px;
  height: 16px;
}

.side-check.checked {
  background: rgba(37, 99, 235, 0.06);
  border-color: rgba(37, 99, 235, 0.25);
}

/* ═══════════ AI CHAT PANEL (Modern) ═══════════ */
.ai-chat-panel {
  flex-shrink: 0;
  border-top: 1px solid var(--border);
  background: var(--card);
  display: flex;
  flex-direction: column;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.ai-chat-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 16px;
  cursor: pointer;
  user-select: none;
  transition: background 0.2s;
}

.ai-chat-toggle:hover {
  background: var(--hover);
}

.ai-chat-toggle-left {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}

.ai-chat-avatar-sm {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: linear-gradient(135deg, #6366f1, #8b5cf6, #a855f7);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.3);
}

.ai-chat-toggle-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.ai-chat-badge {
  font-size: 10px;
  font-weight: 600;
  color: #22c55e;
  background: rgba(34, 197, 94, 0.1);
  padding: 2px 8px;
  border-radius: 10px;
  letter-spacing: 0.3px;
}

.ai-chat-chevron {
  color: var(--muted);
  transform: rotate(180deg);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.ai-chat-panel.open .ai-chat-chevron {
  transform: rotate(0deg);
}

/* Body — hidden when collapsed */
.ai-chat-body {
  display: none;
  flex-direction: column;
  border-top: 1px solid var(--border);
}

.ai-chat-panel.open .ai-chat-body {
  display: flex;
}

/* Messages */
.ai-chat-messages {
  max-height: 220px;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  scroll-behavior: smooth;
}

.ai-chat-messages::-webkit-scrollbar {
  width: 4px;
}

.ai-chat-messages::-webkit-scrollbar-track {
  background: transparent;
}

.ai-chat-messages::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 4px;
}

/* Message row */
.ai-chat-msg {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  animation: chatMsgIn 0.3s ease-out;
}

.ai-chat-msg.user {
  flex-direction: row-reverse;
}

@keyframes chatMsgIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Avatar */
.ai-chat-avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  flex-shrink: 0;
}

.ai-chat-msg.ai .ai-chat-avatar {
  background: linear-gradient(135deg, #6366f1, #a855f7);
  color: #fff;
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(99, 102, 241, 0.25);
}

.ai-chat-msg.user .ai-chat-avatar {
  background: var(--accent);
  color: #fff;
  font-size: 13px;
}

/* Bubble */
.ai-chat-bubble {
  max-width: 80%;
  padding: 10px 14px;
  border-radius: 16px;
  font-size: 13px;
  line-height: 1.55;
}

.ai-chat-msg.ai .ai-chat-bubble {
  background: var(--ai-bubble-bg, rgba(0, 0, 0, 0.04));
  border: 1px solid var(--border);
  border-radius: 4px 16px 16px 16px;
  color: var(--text);
}

.ai-chat-msg.user .ai-chat-bubble {
  background: linear-gradient(135deg, #6366f1, #7c3aed);
  color: #fff;
  border-radius: 16px 4px 16px 16px;
}

/* Input bar */
.ai-chat-input-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  border-top: 1px solid var(--border);
  background: var(--bg);
}

.ai-chat-input-bar input {
  flex: 1;
  padding: 10px 16px;
  border: 1px solid var(--border);
  border-radius: 24px;
  background: var(--card);
  color: var(--text);
  font-size: 13px;
  font-family: var(--font);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.ai-chat-input-bar input:focus {
  border-color: #6366f1;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.12);
}

.ai-chat-input-bar input::placeholder {
  color: var(--muted);
  font-size: 13px;
}

.ai-chat-input-bar button {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: none;
  background: linear-gradient(135deg, #6366f1, #7c3aed);
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: transform 0.15s, box-shadow 0.2s;
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.3);
}

.ai-chat-input-bar button:hover {
  transform: scale(1.08);
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.4);
}

.ai-chat-input-bar button:active {
  transform: scale(0.95);
}

/* Typing indicator dots */
.ai-typing-dots {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 0;
}

.ai-typing-dots span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--muted);
  animation: typingBounce 1.4s infinite ease-in-out both;
}

.ai-typing-dots span:nth-child(1) {
  animation-delay: 0s;
}

.ai-typing-dots span:nth-child(2) {
  animation-delay: 0.16s;
}

.ai-typing-dots span:nth-child(3) {
  animation-delay: 0.32s;
}

@keyframes typingBounce {

  0%,
  80%,
  100% {
    transform: scale(0.6);
    opacity: 0.4;
  }

  40% {
    transform: scale(1);
    opacity: 1;
  }
}

/* ═══════════ MISC ═══════════ */
.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
}

.container.wide {
  max-width: 1440px;
}

.project-switcher {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: var(--panel2);
  border-bottom: 1px solid var(--border);
}

.project-switcher select {
  flex: 1;
  padding: 7px 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius2);
  background: var(--input-bg);
  color: var(--text);
  font-size: 12px;
}

hr.sep {
  border: none;
  border-top: 1px solid var(--border);
  margin: 14px 0;
}

.slots-grid {
  display: grid;
  gap: 6px;
}

.slot {
  padding: 10px;
  border: 1px dashed rgba(255, 255, 255, 0.1);
  border-radius: var(--radius2);
  text-align: center;
  color: var(--muted);
  font-size: 11px;
  cursor: pointer;
  transition: all 0.2s;
}

.slot:hover {
  border-color: rgba(37, 99, 235, 0.3);
  background: rgba(37, 99, 235, 0.04);
}

.slot.occupied {
  border-style: solid;
  background: var(--chip-bg);
  color: var(--text);
}

.draggable {
  padding: 8px 12px;
  background: var(--chip-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius2);
  cursor: grab;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
}

.draggable:active {
  cursor: grabbing;
}

.draggable .icon {
  width: 18px;
  height: 18px;
  background: var(--accent-glow);
  border-radius: 4px;
}

/* ═══════════ PRINT ═══════════ */
@media print {

  .header,
  .footer,
  .nav,
  .burger {
    display: none;
  }

  body {
    background: white;
    color: black;
  }
}

/* ═══════════ COLLAPSIBLE SECTIONS ═══════════ */
.params-section {
  transition: all 0.3s ease;
}

.params-section h3 {
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  user-select: none;
}

.params-section h3::after {
  content: "▼";
  font-size: 10px;
  transition: transform 0.3s ease;
  opacity: 0.5;
}

.params-section h3:hover::after {
  opacity: 1;
}

.params-section.collapsed h3::after {
  transform: rotate(-90deg);
}

.section-content {
  transition: all 0.3s ease;
  overflow: hidden;
  max-height: 2000px;
  opacity: 1;
}

.params-section.collapsed .section-content {
  max-height: 0;
  opacity: 0;
  margin: 0;
  padding: 0;
}

/* ═══════════ CURSOR GLOW ═══════════ */
.cursor-glow {
  position: fixed;
  width: 300px;
  height: 300px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: left 0.12s ease-out, top 0.12s ease-out;
  mix-blend-mode: screen;
  opacity: 0.5;
}

[data-theme="light"] .cursor-glow {
  mix-blend-mode: multiply;
  opacity: 0.3;
}

/* ═══════════ SCROLL REVEAL ═══════════ */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero {
  animation: fadeUp 0.6s ease-out;
}

.hero h1 {
  animation: fadeUp 0.6s ease-out 0.1s both;
}

.hero p {
  animation: fadeUp 0.6s ease-out 0.2s both;
}

.hero-actions {
  animation: fadeUp 0.6s ease-out 0.3s both;
}

/* ═══════════ BATCH 2: LIGHT TOKENS + CORE COMPONENTS ═══════════ */
:root,
[data-theme="light"],
[data-theme="dark"] {
  --bg: #f4f6f8;
  --panel: #ffffff;
  --panel2: #f8fafc;
  --card: #ffffff;
  --muted: #6b7280;
  --text: #10131a;
  --text2: #1f2937;
  --accent: #3f63f6;
  --accent2: #3252d7;
  --accent-glow: rgba(63, 99, 246, 0.12);
  --accent2-glow: rgba(50, 82, 215, 0.1);
  --danger: #dc2626;
  --success: #16a34a;
  --border: rgba(16, 19, 26, 0.12);
  --shadow: 0 1px 2px rgba(16, 19, 26, 0.06);
  --radius: 18px;
  --radius2: 12px;
  --font: "General Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-display: "Satoshi", "General Sans", sans-serif;
  --mono: "SF Mono", "Menlo", monospace;
  --glow-sm: 0 2px 10px rgba(63, 99, 246, 0.08);
  --glow-md: 0 8px 20px rgba(16, 19, 26, 0.08);
  --glow-lg: 0 20px 40px rgba(16, 19, 26, 0.1);
  --header-bg: rgba(255, 255, 255, 0.92);
  --input-bg: #ffffff;
  --logo-bg: transparent;
  --ghost-hover: rgba(16, 19, 26, 0.04);
  --btn-bg: #ffffff;
  --btn-hover: rgba(16, 19, 26, 0.03);
  --btn-border: rgba(16, 19, 26, 0.14);
  --btn-border-hover: rgba(16, 19, 26, 0.22);
  --btn-primary-text: #ffffff;
  --viz-area-bg: #eef2f7;
  --viz-header-bg: rgba(255, 255, 255, 0.92);
  --viz-canvas-bg: #eaf0f7;
  --view-toggle-bg: #f7f9fc;
  --sidebar-bg: #ffffff;
  --params-header-bg: #fbfdff;
  --scrollbar-thumb: rgba(16, 19, 26, 0.22);
  --chip-bg: #ffffff;
  --style-card-bg: #ffffff;
  --style-card-border: rgba(16, 19, 26, 0.12);
  --dim-input-bg: #ffffff;
  --dim-input-border: rgba(16, 19, 26, 0.14);
  --range-input-bg: #ffffff;
  --range-track-bg: rgba(16, 19, 26, 0.1);
  --roof-card-bg: #ffffff;
  --ai-bubble-bg: rgba(63, 99, 246, 0.06);
  --hover: rgba(16, 19, 26, 0.03);
}

body {
  background: linear-gradient(180deg, #f5f8fd 0%, #f2f4f8 100%);
  color: var(--text);
  font-family: var(--font);
}

h1,
h2,
h3 {
  letter-spacing: -0.02em;
}

.theme-toggle {
  display: none;
}

.cursor-glow {
  display: none;
}

.btn {
  min-height: 36px;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--btn-border);
  background: var(--btn-bg);
  color: var(--text2);
  font-weight: 600;
  letter-spacing: 0;
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.btn:hover {
  background: var(--btn-hover);
  border-color: var(--btn-border-hover);
}

.btn.primary {
  background: var(--accent);
  color: var(--btn-primary-text);
  border-color: transparent;
  box-shadow: 0 6px 14px rgba(63, 99, 246, 0.18);
}

.btn.primary:hover {
  background: var(--accent2);
  transform: translateY(-1px);
}

.btn:disabled {
  opacity: 0.48;
  cursor: not-allowed;
}

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

.field {
  gap: 6px;
  margin-bottom: 16px;
}

.label {
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.07em;
}

.input,
.select,
.range-input,
.dim-input {
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--input-bg);
  color: var(--text2);
}

.input:focus,
.select:focus,
.range-input:focus,
.dim-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.range-wrap input[type="range"] {
  height: 5px;
  background: var(--range-track-bg);
}

.range-wrap input[type="range"]::-webkit-slider-thumb {
  width: 18px;
  height: 18px;
  border: 2px solid #fff;
  box-shadow: 0 3px 8px rgba(63, 99, 246, 0.25);
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  border-radius: 999px;
  border: 1px solid var(--border);
  background: #fff;
  color: #4b5563;
  font-weight: 600;
}

.chip:hover {
  border-color: rgba(63, 99, 246, 0.35);
  color: #1f2937;
}

.chip.active {
  border-color: var(--accent);
  background: var(--accent-glow);
  color: var(--accent);
}

.chip.is-disabled {
  opacity: 0.45;
  cursor: not-allowed;
  border-style: dashed;
}

.chip.is-disabled:hover {
  border-color: var(--border);
  color: #4b5563;
}

.view-toggle {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 4px;
}

.view-toggle button {
  padding: 6px 14px;
  border-radius: 9px;
  font-size: 12px;
  font-weight: 600;
}

.view-toggle button.active {
  background: var(--accent-glow);
  color: var(--accent);
}

.params-section {
  border-bottom: 1px solid rgba(16, 19, 26, 0.1);
}

.params-section h3 {
  font-size: 12px;
  letter-spacing: 0.05em;
}

.params-section h3::after {
  opacity: 0.4;
}

.params-section.collapsed h3::after {
  transform: rotate(-90deg);
}



.ai-chat-avatar-sm,
.ai-chat-msg.ai .ai-chat-avatar,
.ai-chat-msg.user .ai-chat-bubble,
.ai-chat-input-bar button {
  background: var(--accent);
  box-shadow: none;
}

.ai-chat-msg.ai .ai-chat-bubble {
  border: 1px solid rgba(63, 99, 246, 0.15);
}

.tm-stepper {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.tm-step {
  min-height: 38px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fff;
  color: #6b7280;
  font-size: 11px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0 8px;
}

.tm-step.is-active {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-glow);
}

.tm-step.is-done {
  color: #0f172a;
}

.tm-accordion {
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #fff;
}

.tm-accordion+.tm-accordion {
  margin-top: 8px;
}

.tm-accordion-head {
  min-height: 44px;
  padding: 0 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.tm-accordion-body {
  border-top: 1px solid var(--border);
  padding: 12px 14px;
}

/* ═══════════ BATCH 3: CONFIGURATOR LAYOUT (TESLA CONTROL PANEL) ═══════════ */
.workspace-v2 {
  display: flex;
  flex-direction: row;
  height: 100%;
}

.workspace-v2 > .viz-area {
  flex: 1;
  min-width: 0;
  min-height: 0;
}

.params-sidebar-v2 {
  flex: 0 0 388px;
  width: 388px;
  border-left: 1px solid var(--border);
}



.params-cta-dock {
  flex-shrink: 0;
  border-top: 1px solid var(--border);
  background: linear-gradient(180deg, rgba(248, 251, 255, 0.96) 0%, rgba(255, 255, 255, 0.98) 100%);
  padding: 12px 14px 14px;
}

.params-cta-price {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.params-cta-price-label {
  font-size: 11px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
}

.params-cta-price-value {
  font-size: 24px;
  color: var(--text);
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: -0.01em;
}

.cta-main-btn {
  width: 100%;
  min-height: 46px;
  font-size: 14px;
}

.params-cta-hint {
  margin: 8px 0 0;
  font-size: 12px;
  line-height: 1.4;
  color: var(--muted);
}

.mobile-cta-bar {
  display: none;
}

.mobile-cta-meta {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.mobile-cta-label {
  font-size: 10px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 600;
}

.mobile-cta-value {
  font-size: 16px;
  color: var(--text);
  font-family: var(--font-display);
  letter-spacing: -0.01em;
}

.mobile-cta-btn {
  min-height: 42px;
  min-width: 196px;
  white-space: nowrap;
}

@media (max-width: 1100px) {
  .workspace-v2 {
    grid-template-columns: 1fr;
    height: auto;
    overflow: visible;
  }

  .viz-area {
    min-height: 54vh;
  }

  .viz-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 12px;
  }

  .cost-breakdown {
    width: 100%;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: nowrap;
  }

  .cost-items {
    flex-wrap: nowrap;
    overflow-x: auto;
    gap: 10px;
    max-width: 100%;
    padding-bottom: 2px;
  }

  .cost-item {
    min-width: 120px;
    align-items: flex-start;
    padding: 0 10px 0 0;
  }

  .params-sidebar-v2 {
    border-left: none;
    border-top: 1px solid var(--border);
    height: auto;
    overflow: visible;
  }

  .params-header-v2 {
    position: sticky;
    top: 55px;
    z-index: 12;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
  }

  .params-body {
    overflow: visible;
    max-height: none;
    padding-bottom: 20px;
  }

  .params-cta-dock {
    display: none;
  }

  .mobile-cta-bar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    background: rgba(255, 255, 255, 0.96);
    border-top: 1px solid var(--border);
    padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
    z-index: 95;
    backdrop-filter: blur(14px);
  }

  .ai-chat-panel {
    margin-bottom: 86px;
  }
}

@media (max-width: 680px) {
  .mobile-cta-btn {
    min-width: 0;
    flex: 1;
  }
}

/* ═══════════ BATCH 4: LANDING REWORK ═══════════ */
.landing-shell {
  padding-top: 28px;
  padding-bottom: 56px;
}

.landing-title {
  margin: 0 0 14px;
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.landing-subtitle {
  margin: 0 0 22px;
  max-width: 720px;
  color: var(--muted);
  font-size: 15px;
}

.landing-hero {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 22px;
  align-items: stretch;
  margin-bottom: 72px;
}

.landing-hero-main,
.landing-blueprint-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: var(--shadow);
}

.landing-hero-main {
  padding: 34px;
}

.landing-eyebrow {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 12px;
  border: 1px solid rgba(63, 99, 246, 0.28);
  border-radius: 999px;
  color: var(--accent);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: var(--accent-glow);
}

.landing-hero-main h1 {
  margin: 14px 0 14px;
  font-size: clamp(34px, 5.6vw, 60px);
  line-height: 1.03;
  letter-spacing: -0.03em;
  color: var(--text);
}

.landing-hero-main h1 .accent {
  color: var(--accent);
}

.landing-hero-main p {
  margin: 0;
  max-width: 680px;
  font-size: 18px;
  line-height: 1.58;
  color: #4b5563;
}

.landing-hero-actions {
  justify-content: flex-start;
  margin-top: 28px;
}

.landing-proof {
  margin-top: 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.landing-proof span {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: #f8fbff;
  color: #374151;
  font-size: 13px;
}

.landing-proof strong {
  margin-right: 4px;
  color: var(--text);
}

.landing-blueprint-card {
  height: 100%;
  padding: 20px;
}

.landing-blueprint-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 12px;
}

.landing-blueprint-head span {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  font-weight: 600;
}

.landing-blueprint-head strong {
  font-size: 18px;
  color: var(--text);
}

.landing-scenario-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.landing-scenario-player {
  --scenario-cycle: 20s;
  position: relative;
  min-height: 312px;
  border: 1px solid rgba(100, 116, 139, 0.2);
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96) 0%, #f7faff 100%);
  overflow: hidden;
}

.landing-scenario-player::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(to bottom, rgba(63, 99, 246, 0.08), transparent 45%),
    repeating-linear-gradient(0deg, transparent, transparent 27px, rgba(148, 163, 184, 0.08) 27px, rgba(148, 163, 184, 0.08) 28px);
}

.landing-scene {
  position: absolute;
  inset: 0;
  padding: 16px;
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 12px;
  opacity: 0;
  transform: translateY(8px) scale(0.99);
  pointer-events: none;
  animation: landingSceneSwap var(--scenario-cycle) linear infinite;
}

.landing-scene-1 {
  animation-delay: 0s;
}

.landing-scene-2 {
  animation-delay: 4s;
}

.landing-scene-3 {
  animation-delay: 8s;
}

.landing-scene-4 {
  animation-delay: 12s;
}

.landing-scene-5 {
  animation-delay: 16s;
}

.landing-scene-head {
  display: flex;
  align-items: center;
  gap: 10px;
}

.landing-scene-head span {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  border: 1px solid rgba(63, 99, 246, 0.3);
  background: rgba(63, 99, 246, 0.1);
  color: var(--accent);
  font-size: 13px;
  font-weight: 700;
  font-family: var(--font-display);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.landing-scene-head h4 {
  margin: 0;
  font-size: 17px;
  letter-spacing: -0.01em;
}

.scene-ui {
  border: 1px solid rgba(100, 116, 139, 0.24);
  border-radius: 14px;
  background: #fff;
  padding: 12px;
  display: grid;
  gap: 10px;
}

.scene-topbar {
  display: flex;
  gap: 6px;
}

.scene-topbar i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(100, 116, 139, 0.4);
}

.scene-row {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
}

.scene-row label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #64748b;
  font-weight: 600;
}

.scene-row b {
  min-width: 44px;
  text-align: right;
  font-size: 13px;
}

.scene-slider {
  --slider-end: 60%;
  --slider-delay: 0s;
  position: relative;
  height: 7px;
  border-radius: 999px;
  background: #e7ebf5;
}

.scene-slider::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 14%;
  border-radius: inherit;
  background: linear-gradient(90deg, #94a3ff, var(--accent));
  animation: sceneSliderFill 3.1s ease-in-out infinite;
  animation-delay: var(--slider-delay);
}

.scene-slider i {
  position: absolute;
  top: 50%;
  left: 14%;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  border: 2px solid #fff;
  background: var(--accent);
  transform: translate(-50%, -50%);
  box-shadow: 0 2px 8px rgba(37, 70, 214, 0.25);
  animation: sceneSliderThumb 3.1s ease-in-out infinite;
  animation-delay: var(--slider-delay);
}

.scene-slider-a {
  --slider-end: 56%;
  --slider-delay: 0.05s;
}

.scene-slider-b {
  --slider-end: 78%;
  --slider-delay: 0.2s;
}

.scene-slider-c {
  --slider-end: 48%;
  --slider-delay: 0.35s;
}

.scene-chat {
  align-content: start;
}

.scene-bubble {
  margin: 0;
  max-width: 86%;
  padding: 8px 10px;
  border-radius: 12px;
  font-size: 12px;
  line-height: 1.4;
  opacity: 0;
  transform: translateY(7px);
  animation: sceneBubbleFlow 3.2s ease-in-out infinite;
}

.scene-bubble-user {
  justify-self: end;
  background: rgba(63, 99, 246, 0.12);
  border: 1px solid rgba(63, 99, 246, 0.26);
}

.scene-bubble-ai {
  justify-self: start;
  background: #f4f7fc;
  border: 1px solid rgba(100, 116, 139, 0.24);
}

.scene-chat .scene-bubble:nth-child(1) {
  animation-delay: 0.15s;
}

.scene-chat .scene-bubble:nth-child(2) {
  animation-delay: 0.95s;
}

.scene-chat .scene-bubble:nth-child(3) {
  animation-delay: 1.72s;
}

.scene-sketches {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: stretch;
}

.scene-sketch {
  position: relative;
  min-height: 132px;
  border: 1px solid rgba(100, 116, 139, 0.28);
  border-radius: 11px;
  background: linear-gradient(180deg, #f8fafc 0%, #eef3ff 100%);
  overflow: hidden;
  animation: sceneSketchPick 3.4s ease-in-out infinite;
}

.scene-sketch::before {
  content: "";
  position: absolute;
  inset: 13px 11px auto 11px;
  height: 56px;
  border-radius: 8px;
  background:
    linear-gradient(160deg, #d6e2f8 45%, #c0d0f0 45% 68%, #a6b8d9 68%),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0));
}

.scene-sketch::after {
  content: "";
  position: absolute;
  left: 11px;
  right: 11px;
  bottom: 28px;
  height: 6px;
  border-radius: 99px;
  background: rgba(100, 116, 139, 0.2);
}

.scene-sketch small {
  position: absolute;
  left: 11px;
  bottom: 9px;
  font-size: 11px;
  font-weight: 600;
  color: #64748b;
}

.scene-sketch-active {
  border-color: rgba(63, 99, 246, 0.38);
  box-shadow: 0 0 0 1px rgba(63, 99, 246, 0.16), 0 8px 20px rgba(37, 70, 214, 0.12);
}

.scene-sketches .scene-sketch:nth-child(1) {
  animation-delay: 0.05s;
}

.scene-sketches .scene-sketch:nth-child(2) {
  animation-delay: 0.95s;
}

.scene-sketches .scene-sketch:nth-child(3) {
  animation-delay: 1.8s;
}

.scene-approve {
  align-content: start;
}

.scene-check {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 36px;
  padding: 0 10px;
  border-radius: 10px;
  border: 1px solid rgba(100, 116, 139, 0.22);
  background: #f8fafc;
  font-size: 12px;
  opacity: 0.38;
  transform: translateX(-4px);
  animation: sceneApproveItem 3.2s ease-in-out infinite;
}

.scene-check i {
  position: relative;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 1px solid rgba(63, 99, 246, 0.45);
  background: #fff;
}

.scene-check i::after {
  content: "";
  position: absolute;
  left: 3px;
  top: 2px;
  width: 6px;
  height: 4px;
  border-left: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  transform: rotate(-45deg) scale(0.8);
  opacity: 0.2;
}

.scene-approve .scene-check:nth-child(1) {
  animation-delay: 0.2s;
}

.scene-approve .scene-check:nth-child(2) {
  animation-delay: 0.92s;
}

.scene-approve .scene-check:nth-child(3) {
  animation-delay: 1.62s;
}

.scene-approve-btn {
  margin-top: 2px;
  height: 36px;
  border-radius: 10px;
  border: 0;
  background: linear-gradient(135deg, var(--accent), #5f7df5);
  color: #fff;
  font-weight: 700;
  letter-spacing: 0.01em;
  animation: sceneApproveButton 3.2s ease-in-out infinite;
  animation-delay: 1.9s;
}

.scene-docs {
  align-content: start;
}

.scene-progress {
  height: 10px;
  border-radius: 999px;
  background: #e7ebf5;
  overflow: hidden;
}

.scene-progress em {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #94a3ff, var(--accent));
  animation: sceneDocsProgress 3.3s linear infinite;
}

.scene-file {
  min-height: 36px;
  border-radius: 10px;
  border: 1px solid rgba(100, 116, 139, 0.24);
  background: #f8fafc;
  padding: 0 11px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  opacity: 0.38;
  transform: translateY(6px);
  animation: sceneDocFile 3.2s ease-in-out infinite;
}

.scene-file::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 2px;
  background: rgba(63, 99, 246, 0.36);
  box-shadow: inset 0 0 0 1px rgba(63, 99, 246, 0.5);
}

.scene-docs .scene-file:nth-child(2) {
  animation-delay: 0.65s;
}

.scene-docs .scene-file:nth-child(3) {
  animation-delay: 1.28s;
}

.scene-docs .scene-file:nth-child(4) {
  animation-delay: 1.92s;
}

.landing-scenario-dots {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  margin-top: 2px;
}

.landing-scenario-dot-item {
  height: 6px;
  border-radius: 999px;
  background: #dbe3f4;
  animation: landingScenarioDotActive 20s linear infinite;
}

.landing-scenario-dot-1 {
  animation-delay: 0s;
}

.landing-scenario-dot-2 {
  animation-delay: 4s;
}

.landing-scenario-dot-3 {
  animation-delay: 8s;
}

.landing-scenario-dot-4 {
  animation-delay: 12s;
}

.landing-scenario-dot-5 {
  animation-delay: 16s;
}

@keyframes landingSceneSwap {
  0% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }

  18% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }

  20%,
  100% {
    opacity: 0;
    transform: translateY(-6px) scale(0.993);
  }
}

@keyframes landingScenarioDotActive {

  0%,
  18% {
    background: rgba(63, 99, 246, 0.26);
    box-shadow: inset 0 0 0 1px rgba(63, 99, 246, 0.42);
  }

  20%,
  100% {
    background: #dbe3f4;
    box-shadow: none;
  }
}

@keyframes sceneSliderFill {

  0%,
  12% {
    width: 14%;
  }

  54%,
  100% {
    width: var(--slider-end);
  }
}

@keyframes sceneSliderThumb {

  0%,
  12% {
    left: 14%;
  }

  54%,
  100% {
    left: var(--slider-end);
  }
}

@keyframes sceneBubbleFlow {

  0%,
  16% {
    opacity: 0;
    transform: translateY(7px);
  }

  30%,
  82% {
    opacity: 1;
    transform: translateY(0);
  }

  100% {
    opacity: 0;
    transform: translateY(-4px);
  }
}

@keyframes sceneSketchPick {

  0%,
  18%,
  100% {
    border-color: rgba(100, 116, 139, 0.28);
    box-shadow: none;
    transform: translateY(0);
  }

  34%,
  70% {
    border-color: rgba(63, 99, 246, 0.42);
    box-shadow: 0 0 0 1px rgba(63, 99, 246, 0.16), 0 8px 18px rgba(37, 70, 214, 0.12);
    transform: translateY(-2px);
  }
}

@keyframes sceneApproveItem {

  0%,
  22%,
  100% {
    opacity: 0.38;
    transform: translateX(-4px);
    border-color: rgba(100, 116, 139, 0.22);
  }

  34%,
  74% {
    opacity: 1;
    transform: translateX(0);
    border-color: rgba(63, 99, 246, 0.34);
  }
}

@keyframes sceneApproveButton {

  0%,
  58%,
  100% {
    transform: scale(1);
    box-shadow: none;
  }

  74% {
    transform: scale(1.015);
    box-shadow: 0 10px 22px rgba(37, 70, 214, 0.28);
  }
}

@keyframes sceneDocsProgress {
  0% {
    width: 0;
  }

  78% {
    width: 100%;
  }

  100% {
    width: 100%;
  }
}

@keyframes sceneDocFile {

  0%,
  20%,
  100% {
    opacity: 0.38;
    transform: translateY(6px);
    border-color: rgba(100, 116, 139, 0.24);
  }

  34%,
  74% {
    opacity: 1;
    transform: translateY(0);
    border-color: rgba(63, 99, 246, 0.34);
  }
}

.landing-flow {
  margin-top: 14px;
}

.landing-flow-svg {
  width: 100%;
  color: #6b7280;
}

.landing-flow-grid {
  margin-top: 16px;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}

.landing-flow-card {
  padding: 18px 16px;
}

.landing-flow-card span {
  display: inline-block;
  font-size: 22px;
  line-height: 1;
  margin-bottom: 10px;
  color: var(--accent);
  font-weight: 800;
  font-family: var(--font-display);
}

.landing-flow-card h4,
.landing-value-card h4 {
  margin: 0 0 8px;
  font-size: 18px;
  line-height: 1.2;
  color: var(--text);
}

.landing-flow-card p,
.landing-value-card p {
  margin: 0;
  color: #4b5563;
}

.landing-samples,
.landing-value,
.landing-projects,
.landing-contacts {
  margin-top: 72px;
}

.landing-value-card {
  min-height: 180px;
  padding: 22px;
}

.landing-value-card svg {
  width: 52px;
  height: 52px;
  margin-bottom: 12px;
  color: #64748b;
}

@media (max-width: 1100px) {
  .landing-hero {
    grid-template-columns: 1fr;
  }

  .landing-scenario-player {
    min-height: 286px;
  }

  .landing-flow-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .landing-shell {
    padding-top: 14px;
  }

  .landing-hero-main {
    padding: 20px;
  }

  .landing-hero-main p {
    font-size: 16px;
  }

  .landing-hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

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

  .landing-flow-grid {
    grid-template-columns: 1fr;
  }

  .landing-flow-svg {
    display: none;
  }

  .landing-scenario-player {
    min-height: 272px;
  }

  .landing-scene {
    padding: 14px;
  }

  .scene-row {
    grid-template-columns: 56px minmax(0, 1fr) auto;
    gap: 8px;
  }

  .scene-sketch {
    min-height: 116px;
  }

  .landing-title {
    font-size: 13px;
  }
}

/* ═══════════ BATCH 6: BRAND LOGO ANIMATION ═══════════ */
.logo {
  width: 56px;
  height: 56px;
}

.logo svg.brand-logo-svg {
  width: 52px;
  height: 52px;
  overflow: visible;
}

.brand-logo-frame,
.brand-logo-axis,
.brand-logo-stem {
  stroke: var(--accent);
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

.brand-logo-frame {
  stroke-width: 1.8;
  opacity: 0.25;
}

.brand-logo-axis {
  stroke-width: 3;
  stroke-dasharray: 20;
  stroke-dashoffset: 20;
  animation: brandAxisLoop 3.4s ease-in-out infinite;
}

.brand-logo-stem {
  stroke-width: 3;
  stroke-dasharray: 18;
  stroke-dashoffset: 18;
  animation: brandStemLoop 3.4s ease-in-out .22s infinite;
}

.brand-logo-node {
  fill: var(--accent);
  transform-origin: center;
  animation: brandNodePulse 3.4s ease-in-out infinite;
}

@keyframes brandAxisLoop {
  0% {
    stroke-dashoffset: 20;
  }

  24%,
  64% {
    stroke-dashoffset: 0;
  }

  86%,
  100% {
    stroke-dashoffset: 20;
  }
}

@keyframes brandStemLoop {

  0%,
  6% {
    stroke-dashoffset: 18;
  }

  28%,
  64% {
    stroke-dashoffset: 0;
  }

  86%,
  100% {
    stroke-dashoffset: 18;
  }
}

@keyframes brandNodePulse {

  0%,
  24%,
  64%,
  100% {
    transform: scale(1);
    opacity: 1;
  }

  36%,
  44% {
    transform: scale(1.18);
    opacity: 0.75;
  }
}

@media (prefers-reduced-motion: reduce) {

  .landing-scene,
  .landing-scenario-dot-item,
  .scene-slider::before,
  .scene-slider i,
  .scene-bubble,
  .scene-sketch,
  .scene-check,
  .scene-approve-btn,
  .scene-progress em,
  .scene-file,
  .brand-logo-axis,
  .brand-logo-stem,
  .brand-logo-node {
    animation: none !important;
    stroke-dashoffset: 0;
  }

  .landing-scene {
    opacity: 0;
    transform: none;
  }

  .landing-scene-1 {
    opacity: 1;
  }

  .landing-scenario-dot-item {
    background: #dbe3f4;
    box-shadow: none;
  }

  .landing-scenario-dot-1 {
    background: rgba(63, 99, 246, 0.26);
    box-shadow: inset 0 0 0 1px rgba(63, 99, 246, 0.42);
  }

  .scene-slider::before {
    width: var(--slider-end);
  }

  .scene-slider i {
    left: var(--slider-end);
  }

  .scene-bubble,
  .scene-sketch,
  .scene-check,
  .scene-file {
    opacity: 1;
    transform: none;
  }

  .scene-progress em {
    width: 100%;
  }
}

/* ═══════════ STEP INDICATOR ═══════════ */
.step-indicator {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  z-index: 50;
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  filter: drop-shadow(0 4px 12px rgba(0,0,0,0.1));
  pointer-events: none;
}

.step-indicator.collapsed {
  transform: translate(-50%, calc(-100% + 20px));
}

.step-indicator-wrapper {
  background: var(--viz-header-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding: 8px 36px 12px;
  display: flex;
  align-items: center;
  gap: 0;
  border: 1px solid var(--border);
  border-top: none;
  border-radius: 0 0 24px 24px;
  pointer-events: auto;
}

.step-indicator-toggle {
  width: 54px;
  height: 20px;
  background: var(--viz-header-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border);
  border-top: none;
  border-radius: 0 0 10px 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--muted);
  transition: all 0.2s;
  margin-top: -1px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
  pointer-events: auto;
}

.step-indicator-toggle:hover {
  color: var(--accent);
  background: var(--hover);
}

.step-indicator-toggle svg {
  width: 14px;
  height: 14px;
  transition: transform 0.3s;
}

.step-indicator.collapsed .step-indicator-toggle svg {
  transform: rotate(180deg);
}

.step-dot {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  cursor: default;
  transition: all 0.25s;
  user-select: none;
}

.step-num {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  background: var(--border);
  color: var(--muted);
  transition: all 0.25s;
}

.step-label {
  font-size: 11px;
  font-weight: 500;
  color: var(--muted);
  white-space: nowrap;
  transition: color 0.25s;
}

.step-dot.active .step-num {
  background: var(--accent);
  color: var(--btn-primary-text);
  box-shadow: 0 2px 6px rgba(99, 102, 241, 0.35);
}

.step-dot.active .step-label {
  color: var(--text);
  font-weight: 600;
}

.step-dot.done .step-num {
  background: rgba(34, 197, 94, 0.15);
  color: #22c55e;
}

.step-dot.done .step-label {
  color: var(--text2);
}

.step-line {
  width: 28px;
  height: 1px;
  background: var(--border);
  flex-shrink: 0;
}

/* ═══════════ COLLAPSED SIDEBAR ═══════════ */
.sidebar-collapsed {
  width: 380px;
}

.sidebar-collapsed .params-header,
.sidebar-collapsed .params-body,
.sidebar-collapsed .params-cta-dock {
  display: none;
}

.params-collapsed-tab {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  transition: all 0.2s;
  background: var(--params-header-bg);
  flex-shrink: 0;
}

.params-collapsed-tab:hover {
  color: var(--accent);
  background: var(--hover);
}

.params-collapsed-tab svg {
  transition: transform 0.2s;
}

.params-collapsed-tab:hover svg {
  transform: translateX(2px);
}

/* ═══════════ FACADE GALLERY ═══════════ */
.facade-gallery {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.facade-gallery-header {
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
}

.facade-gallery-header h3 {
  margin: 8px 0 0;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}

.facade-gallery-body {
  flex: 1;
  overflow-y: auto;
  padding: 14px;
}

.facade-gallery-body::-webkit-scrollbar {
  width: 4px;
}

.facade-gallery-body::-webkit-scrollbar-thumb {
  background: var(--scrollbar-thumb);
  border-radius: 4px;
}

.facade-empty {
  text-align: center;
  padding: 40px 20px;
  color: var(--muted);
}

.facade-empty-icon {
  font-size: 48px;
  margin-bottom: 16px;
  opacity: 0.5;
}

.facade-empty p {
  font-size: 13px;
  line-height: 1.5;
}

.facade-grid {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.facade-card {
  position: relative;
  border: 2px solid var(--border);
  border-radius: var(--radius2);
  overflow: hidden;
  cursor: pointer;
  transition: all 0.25s;
  background: var(--card);
}

.facade-card:hover {
  border-color: rgba(99, 102, 241, 0.3);
  box-shadow: 0 4px 16px rgba(99, 102, 241, 0.1);
  transform: translateY(-2px);
}

.facade-card.selected {
  border-color: var(--accent);
  box-shadow: 0 4px 20px rgba(99, 102, 241, 0.2);
}

.facade-selector-overlay {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 5;
}

.facade-radio-indicator {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.8);
  background: rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(4px);
  position: relative;
  transition: all 0.2s;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.facade-card:hover .facade-radio-indicator {
  border-color: #fff;
  transform: scale(1.1);
}

.facade-radio-indicator.active {
  background: var(--accent);
  border-color: var(--accent);
  box-shadow: 0 0 12px var(--accent-glow);
}

.facade-radio-indicator.active::after {
  content: '✓';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: #fff;
  font-size: 13px;
  font-weight: 800;
}

.facade-card-renders {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2px;
}

.facade-render {
  position: relative;
  overflow: hidden;
  cursor: pointer;
  aspect-ratio: 16/10;
}

.facade-render img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s;
}

.facade-render:hover img {
  transform: scale(1.05);
}

.facade-render-zoom {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.5);
  border-radius: 6px;
  font-size: 13px;
  opacity: 0;
  transition: opacity 0.2s;
  pointer-events: none;
}

.facade-render:hover .facade-render-zoom {
  opacity: 1;
}

/* ═══════════ IMAGE LIGHTBOX ═══════════ */
.lightbox-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1100;
  backdrop-filter: blur(8px);
  animation: fadeIn 0.2s ease-out;
  cursor: pointer;
}

.lightbox-content {
  position: relative;
  max-width: 90vw;
  max-height: 90vh;
  cursor: default;
}

.lightbox-img {
  max-width: 90vw;
  max-height: 85vh;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 20px 80px rgba(0, 0, 0, 0.5);
  animation: modalSlideIn 0.3s ease-out;
}

.lightbox-close {
  position: absolute;
  top: -40px;
  right: 0;
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.8);
  font-size: 28px;
  cursor: pointer;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.2s;
}

.lightbox-close:hover {
  color: white;
  background: rgba(255, 255, 255, 0.1);
}

.lightbox-caption {
  text-align: center;
  color: rgba(255, 255, 255, 0.7);
  font-size: 13px;
  font-weight: 500;
  margin-top: 12px;
  letter-spacing: 0.02em;
}

.facade-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
}

.facade-card-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}

.facade-card-badge {
  font-size: 11px;
  font-weight: 600;
  color: #22c55e;
  background: rgba(34, 197, 94, 0.1);
  padding: 3px 10px;
  border-radius: 12px;
}

.facade-card-badge.ghost {
  color: var(--muted);
  background: rgba(255, 255, 255, 0.05);
  border: 1px dashed var(--border);
}

.facade-action-bar {
  padding: 14px 0 0;
}

.facade-action-bar .btn {
  width: 100%;
}

.facade-action-hint {
  font-size: 11px;
  color: var(--muted);
  text-align: center;
  margin-top: 10px;
  font-style: italic;
}

/* ═══════════ AI GENERATION PANEL (Step 2) ═══════════ */
.ai-gen-panel {
  flex-shrink: 0;
  border-top: 1px solid var(--border);
  background: var(--card);
  display: flex;
  flex-direction: column;
}

.ai-gen-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}

.ai-gen-body {
  display: flex;
  flex-direction: column;
  max-height: 60vh;
  overflow-y: auto;
}

.ai-gen-messages {
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 120px;
  overflow-y: auto;
}

.ai-gen-settings {
  padding: 10px 16px 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  border-top: 1px solid var(--border);
}

.ai-gen-setting .label {
  margin-bottom: 6px;
}

.ai-gen-prompt {
  resize: vertical;
  min-height: 60px;
  font-family: var(--font);
}

.ai-gen-row {
  display: flex;
  gap: 14px;
}

.ai-gen-hint-row {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  color: var(--muted);
  margin-top: 4px;
}

.ai-gen-checkbox {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  color: var(--fg);
  user-select: none;
}

.ai-gen-checkbox input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  width: 18px;
  height: 18px;
  border: 2px solid var(--border);
  border-radius: 4px;
  cursor: pointer;
  position: relative;
  flex-shrink: 0;
  transition: all 0.2s;
}

.ai-gen-checkbox input[type="checkbox"]:checked {
  background: var(--accent);
  border-color: var(--accent);
}

.ai-gen-checkbox input[type="checkbox"]:checked::after {
  content: '✓';
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 12px;
  font-weight: 700;
}

/* ═══════════ PAYMENT STEP ═══════════ */
.payment-step {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 16px 14px;
  height: 100%;
  overflow-y: auto;
}

.sidebar-payment {
  width: 380px;
}

.payment-card {
  text-align: center;
}

.payment-icon {
  font-size: 36px;
  margin-bottom: 4px;
}

.payment-card h3 {
  margin: 0 0 6px;
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
}

.payment-desc {
  font-size: 12px;
  color: var(--muted);
  margin: 0 0 14px;
  line-height: 1.5;
}

.payment-summary {
  text-align: left;
  background: var(--panel2);
  border: 1px solid var(--border);
  border-radius: var(--radius2);
  padding: 10px 12px;
  margin-bottom: 14px;
}

.payment-row {
  display: flex;
  justify-content: space-between;
  padding: 6px 0;
  font-size: 13px;
  color: var(--text2);
}

.payment-row.total {
  font-weight: 700;
  font-size: 16px;
  color: var(--text);
  padding-top: 10px;
}

.payment-divider {
  height: 1px;
  background: var(--border);
  margin: 6px 0;
}

.payment-pipeline {
  text-align: left;
  margin-bottom: 14px;
}

.payment-pipeline h4 {
  margin: 0 0 10px;
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.pipeline-items {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pipeline-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--text2);
  padding: 8px 12px;
  background: var(--panel2);
  border: 1px solid var(--border);
  border-radius: var(--radius2);
}

.pipeline-icon {
  font-size: 16px;
}

.payment-actions {
  display: flex;
  gap: 10px;
  justify-content: center;
}

.payment-actions .btn {
  min-width: 140px;
}

/* ═══════════ CONFIRM MODAL ═══════════ */
.confirm-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  backdrop-filter: blur(4px);
  animation: fadeIn 0.2s ease-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

.confirm-modal {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  max-width: 400px;
  width: 90%;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  animation: modalSlideIn 0.25s ease-out;
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translateY(-20px) scale(0.95);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.confirm-modal h3 {
  margin: 0 0 10px;
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
}

.confirm-modal p {
  margin: 0 0 20px;
  font-size: 14px;
  color: var(--muted);
  line-height: 1.5;
}

.confirm-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
}

/* ═══════════ ACCOUNT DASHBOARD ═══════════ */
.account-panel {
  max-width: 900px;
  margin: 24px auto;
}

.account-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
}

.account-header h2 {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
}

.account-empty {
  text-align: center;
  padding: 60px 20px;
  color: var(--muted);
}

.account-empty-icon {
  font-size: 48px;
  margin-bottom: 12px;
  opacity: 0.5;
}

.projects-grid {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.project-card {
  background: var(--panel2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.project-card:hover {
  border-color: var(--accent);
  box-shadow: 0 4px 16px rgba(99, 102, 241, 0.08);
}

.project-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.project-card-header h3 {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
}

.project-status {
  font-size: 11px;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 12px;
}

.status-pending {
  background: rgba(255, 193, 7, 0.12);
  color: #f59e0b;
}

.status-paid {
  background: rgba(59, 130, 246, 0.12);
  color: #3b82f6;
}

.status-gen {
  background: rgba(99, 102, 241, 0.12);
  color: var(--accent);
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.6;
  }
}

.status-ready {
  background: rgba(34, 197, 94, 0.12);
  color: #22c55e;
}

.project-meta {
  display: flex;
  gap: 20px;
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 14px;
}

.project-pipeline {
  display: flex;
  align-items: center;
  gap: 4px;
}

.project-pipeline-stage {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 500;
  color: var(--muted);
  background: var(--hover);
  transition: all 0.2s;
}

.project-pipeline-stage.active {
  color: var(--accent);
  background: var(--accent-glow);
}

.project-pipeline-stage.current {
  animation: pulse 2s ease-in-out infinite;
}

.project-pipeline-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--border);
  transition: background 0.2s;
}

.project-pipeline-stage.active .project-pipeline-dot {
  background: var(--accent);
}

/* ═══════════ WORKSPACE STEP-FACADE MODE ═══════════ */
.workspace.step-facade {
  grid-template-columns: 1fr 380px;
  grid-template-rows: auto 1fr;
}

.workspace.step-facade .step-indicator {
  grid-column: 1 / -1;
}

.workspace:not(.step-facade) {
  grid-template-rows: auto 1fr;
}

.workspace:not(.step-facade) .step-indicator {
  grid-column: 1 / -1;
}

@media (max-width: 1100px) {
  .step-indicator {
    padding: 8px 12px;
    gap: 0;
    overflow-x: auto;
  }

  .step-label {
    display: none;
  }

  .step-line {
    width: 20px;
  }

  .sidebar-collapsed,
  .sidebar-payment {
    width: auto;
  }

  .workspace.step-facade {
    grid-template-columns: 1fr;
  }

  .ai-gen-body {
    max-height: none;
  }

  .project-pipeline {
    flex-wrap: wrap;
  }
}

/* ═══════════ PARAPET CHECKBOXES ═══════════ */
.parapet-checks {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.parapet-check {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
}

.parapet-check:hover {
  border-color: rgba(63, 99, 246, 0.35);
  background: rgba(63, 99, 246, 0.02);
}

.parapet-check.checked {
  border-color: var(--accent);
  background: var(--accent-glow);
}

.parapet-check.is-disabled {
  opacity: 0.6;
  cursor: not-allowed;
  border-style: dashed;
}

.parapet-check.is-disabled:hover {
  border-color: var(--border);
  background: #fff;
}

.parapet-check.is-disabled.checked {
  background: rgba(63, 99, 246, 0.05);
  border-color: rgba(63, 99, 246, 0.25);
  border-style: solid;
}

.parapet-check input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
  width: 0;
  height: 0;
}

.parapet-check-box {
  width: 18px;
  height: 18px;
  border: 1.5px solid var(--border);
  border-radius: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.2s ease;
  color: transparent;
  background: #fff;
}

.parapet-check.checked .parapet-check-box {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
}

.parapet-check-box svg {
  width: 12px;
  height: 12px;
}

.parapet-check-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text2);
}

.parapet-hint {
  margin-top: 4px;
  font-size: 11px;
  color: var(--muted);
  font-style: italic;
  padding: 0 2px;
}

/* ═══════════ PARAPET MAP ═══════════ */
.parapet-map-container {
  display: flex;
  justify-content: center;
  padding: 10px 0;
  margin-top: 10px;
}

.parapet-map {
  display: grid;
  grid-template-columns: 80px 100px 80px;
  grid-template-rows: 40px 100px 40px;
  align-items: center;
  justify-items: center;
  gap: 10px;
  position: relative;
}

.building-footprint {
  grid-area: 2 / 2;
  width: 100%;
  height: 100%;
  background: var(--input-bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  position: relative;
  overflow: hidden;
}

.side-indicator {
  position: absolute;
  background: var(--accent);
  opacity: 0;
  transition: opacity 0.2s;
}

.side-indicator.top {
  top: 0;
  left: 0;
  width: 100%;
  height: 6px;
}

.side-indicator.bottom {
  bottom: 0;
  left: 0;
  width: 100%;
  height: 6px;
}

.side-indicator.left {
  top: 0;
  left: 0;
  width: 6px;
  height: 100%;
}

.side-indicator.right {
  top: 0;
  right: 0;
  width: 6px;
  height: 100%;
}

.side-indicator.active {
  opacity: 1;
}

.parapet-side-check {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  transition: all 0.2s;
  width: 100%;
}

.parapet-side-check.is-disabled {
  cursor: not-allowed;
  opacity: 0.5;
}

.parapet-side-check.top {
  grid-area: 1 / 2;
}

.parapet-side-check.bottom {
  grid-area: 3 / 2;
}

.parapet-side-check.left {
  grid-area: 2 / 1;
}

.parapet-side-check.right {
  grid-area: 2 / 3;
}

.parapet-side-check .p-box {
  width: 20px;
  height: 20px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--btn-bg);
  position: relative;
  transition: all 0.2s;
}

.parapet-side-check:hover .p-box {
  border-color: var(--accent);
}

.parapet-side-check.checked .p-box {
  background: var(--accent);
  border-color: var(--accent);
  box-shadow: var(--glow-sm);
}

.parapet-side-check.checked .p-box::after {
  content: '✓';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
}

.parapet-side-check .p-label {
  font-size: 10px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 500;
}

.parapet-side-check.checked .p-label {
  color: var(--text);
  font-weight: 600;
}

.parapet-side-check input {
  display: none;
}

.parapet-hint {
  font-size: 11px;
  color: var(--muted);
  background: var(--accent-glow);
  padding: 8px 12px;
  border-radius: 8px;
  margin-top: 15px;
  line-height: 1.4;
  border-left: 3px solid var(--accent);
}

.cost-item.area-stat {
  border-right: 2px solid var(--accent) !important;
  margin-right: 8px;
  padding-right: 16px;
}

.cost-item.area-stat .cost-label {
  color: var(--accent);
  font-weight: 700;
}

.cost-item.area-stat .cost-value {
  font-size: 18px;
  color: var(--accent);
  font-weight: 800;
}