/* =============================================================
   Resize.one — Design System
   ============================================================= */

/* --- Tokens --- */
:root {
  --primary: #2D5A54;
  --primary-light: #ECF3F2;
  --primary-dark: #22443F;
  --accent: #64B6AC;
  --success: #10B981;
  --danger: #EF4444;

  --bg: #f0f2f5;
  --surface: rgba(255, 255, 255, 0.75);
  --surface-solid: #ffffff;
  --glass-bg: rgba(255, 255, 255, 0.45);
  --glass-border: rgba(255, 255, 255, 0.5);

  --border: rgba(0, 0, 0, 0.08);
  --border-focus: #2D5A54;

  --text-1: #1a1d23;
  --text-2: #4a5568;
  --text-3: #a0aec0;

  --nav-h: 64px;
  --sidebar-w: 320px;
  --radius: 12px;
  --radius-lg: 20px;
  --radius-xl: 28px;

  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.02), 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.05), 0 4px 6px -2px rgba(0, 0, 0, 0.03);
  --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.08), 0 10px 10px -5px rgba(0, 0, 0, 0.03);
  --glass-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.07);

  --ff: 'Inter', system-ui, -apple-system, sans-serif;
  --transition: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}


/* --- Reset --- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--ff);
  background: var(--bg);
  color: var(--text-1);
  -webkit-font-smoothing: antialiased;
  transition: background var(--transition), color var(--transition);
}

a {
  color: var(--primary);
  text-decoration: none;
}

a:hover {
  color: var(--primary-dark);
}

button {
  font-family: inherit;
  border: none;
  background: none;
  cursor: pointer;
}

input,
select {
  font-family: inherit;
}

/* =============================================================
   Buttons
   ============================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .45rem;
  padding: .65rem 1.25rem;
  border-radius: var(--radius);
  font-size: .875rem;
  font-weight: 600;
  transition: all var(--transition);
  line-height: 1;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 4px 12px rgba(45, 90, 84, .25);
}

.btn-primary:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(45, 90, 84, .35);
}

.btn-process {
  background: linear-gradient(135deg, #2D5A54, #64B6AC);
  color: #fff;
  box-shadow: 0 4px 14px rgba(45, 90, 84, .3);
}

.btn-process:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(45, 90, 84, .4);
}

.btn-process:disabled {
  opacity: .6;
  cursor: not-allowed;
  transform: none;
}

.btn-secondary {
  background: var(--surface);
  color: var(--text-2);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  background: var(--surface-2);
  color: var(--text-1);
}

.btn-ghost {
  color: var(--text-2);
  padding: .5rem .75rem;
}

.btn-ghost:hover {
  background: var(--surface-2);
  color: var(--text-1);
  border-radius: var(--radius);
}

.btn-danger-soft {
  background: #FEE2E2;
  color: var(--danger);
}

.btn-danger-soft:hover {
  background: #FECACA;
}

.btn-sm {
  padding: .45rem .9rem;
  font-size: .8rem;
}

/* =============================================================
   Layout
   ============================================================= */
.app-container {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* --- Navbar --- */
.navbar {
  height: var(--nav-h);
  background: #ffffff;
  /* Solid white navbar */
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.75rem;
  position: sticky;
  top: 0;
  z-index: 1000;
  /* Ensure it's above everything */
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.02);
}

.logo {
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: .5rem;
  letter-spacing: -.01em;
}

.logo i {
  font-size: 1.1rem;
}

.nav-center {
  display: flex;
  gap: .25rem;
  align-items: center;
}

.nav-link {
  padding: .4rem .85rem;
  border-radius: 8px;
  font-size: .875rem;
  font-weight: 500;
  color: var(--text-2);
  transition: all var(--transition);
}

.nav-link:hover {
  color: var(--primary);
  background: var(--primary-light);
}

.nav-link.active {
  color: var(--primary);
  background: var(--primary-light);
  font-weight: 600;
}

/* Mobile Nav Toggle */
.menu-toggle {
  display: none;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--primary-light);
  color: var(--primary);
  border: none;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  transition: all 0.3s ease;
}

.menu-toggle:hover {
  background: var(--primary);
  color: #fff;
}

/* Mobile Drawer Overlay */
.nav-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(4px);
  z-index: 1001;
  opacity: 0;
  visibility: hidden;
  transition: all 0.4s ease;
}

.nav-overlay.active {
  opacity: 1;
  visibility: visible;
}

/* Side Drawer */
.side-drawer {
  position: fixed;
  top: 0;
  right: -300px;
  width: 280px;
  height: 100%;
  background: #ffffff;
  z-index: 1002;
  box-shadow: -10px 0 30px rgba(0, 0, 0, 0.05);
  display: flex;
  flex-direction: column;
  padding: 2rem 1.5rem;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.side-drawer.active {
  right: 0;
}

.drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2.5rem;
}

.drawer-links {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.drawer-link {
  padding: 1rem;
  border-radius: 12px;
  color: var(--text-1);
  font-weight: 600;
  font-size: 1rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  transition: all 0.3s ease;
}

.drawer-link i {
  width: 20px;
  color: var(--text-3);
  transition: color 0.3s ease;
}

.drawer-link:hover,
.drawer-link.active {
  background: var(--primary-light);
  color: var(--primary);
}

.drawer-link:hover i,
.drawer-link.active i {
  color: var(--primary);
}

.drawer-footer {
  margin-top: auto;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
}

.drawer-social {
  display: flex;
  gap: 1rem;
  margin-top: 1rem;
}

.drawer-social a {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--surface-2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-2);
  font-size: 1.1rem;
  transition: all 0.3s ease;
}

.drawer-social a:hover {
  background: var(--primary);
  color: #fff;
  transform: translateY(-3px);
}

/* --- Workspace --- */
.workspace {
  display: flex;
  flex: 1;
  height: calc(100vh - var(--nav-h));
  overflow: hidden;
}

/* --- Sidebar --- */
.sidebar {
  width: var(--sidebar-w);
  flex-shrink: 0;
  background: var(--surface);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-right: 1px solid var(--glass-border);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  z-index: 20;
}

.sidebar-section {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--border);
}

.sidebar-section:last-child {
  border-bottom: none;
}

.section-title {
  font-size: .7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--text-3);
  margin-bottom: 1rem;
}

/* Form controls */
.field {
  display: flex;
  flex-direction: column;
  gap: .4rem;
  margin-bottom: .85rem;
}

.field:last-child {
  margin-bottom: 0;
}

.field label {
  font-size: .8rem;
  font-weight: 500;
  color: var(--text-2);
}

.input-wrap {
  position: relative;
}

.input-wrap input,
.input-wrap select,
.field select {
  width: 100%;
  padding: .6rem .85rem;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--text-1);
  font-size: .875rem;
  transition: border-color var(--transition), box-shadow var(--transition);
  appearance: none;
}

.input-wrap input:focus,
.input-wrap select:focus,
.field select:focus {
  outline: none;
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px rgba(91, 80, 232, .12);
}

.input-wrap .unit {
  position: absolute;
  right: .75rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-3);
  font-size: .75rem;
  font-weight: 500;
  pointer-events: none;
}

.input-wrap input[type=number] {
  padding-right: 2rem;
}

.dim-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: .6rem;
}

.toggle-row {
  display: flex;
  align-items: center;
  gap: .5rem;
  padding: .4rem 0;
}

.toggle-row input[type=checkbox] {
  accent-color: var(--primary);
  width: 15px;
  height: 15px;
  flex-shrink: 0;
}

.toggle-row span {
  font-size: .8rem;
  color: var(--text-2);
}

/* Range slider */
.range-row {
  display: flex;
  align-items: center;
  gap: .75rem;
}

input[type=range] {
  flex: 1;
  accent-color: var(--primary);
  height: 4px;
  cursor: pointer;
}

.range-val {
  font-size: .8rem;
  font-weight: 700;
  color: var(--primary);
  min-width: 2.5rem;
  text-align: right;
  flex-shrink: 0;
}

/* Sidebar footer */
.sidebar-footer {
  padding: 1.25rem 1.5rem;
  margin-top: auto;
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: .6rem;
}

.sidebar-footer .btn {
  width: 100%;
  justify-content: center;
}

/* =============================================================
   Canvas / Upload Area
   ============================================================= */
.canvas-area {
  flex: 1;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  padding: 1.5rem;
  gap: 1.25rem;
}

/* Toolbar row */
.canvas-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: .75rem;
}

.canvas-toolbar h1 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-1);
  display: flex;
  align-items: center;
  gap: .5rem;
}

.count-badge {
  background: var(--primary-light);
  color: var(--primary);
  font-size: .72rem;
  font-weight: 700;
  padding: .2rem .55rem;
  border-radius: 999px;
}

.toolbar-right {
  display: flex;
  gap: .5rem;
  align-items: center;
}

/* Upload Zone */
/* --- Upload Zone --- */
.upload-zone {
  border: 2px dashed rgba(45, 90, 84, 0.15);
  border-radius: var(--radius-xl);
  background: #ffffff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  text-align: center;
  cursor: pointer;
  min-height: 380px;
  padding: 4rem 2rem;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 4px 25px rgba(0, 0, 0, 0.02);
}

.upload-zone:hover,
.upload-zone.dragover {
  border-color: var(--primary);
  background: var(--primary-light);
  transform: scale(1.005);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.04);
}

.upload-zone .uz-icon {
  width: 80px;
  height: 80px;
  border-radius: 24px;
  background: var(--primary-light);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  margin-bottom: 1rem;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.upload-zone:hover .uz-icon {
  transform: translateY(-5px) rotate(2deg);
  background: var(--primary);
  color: #fff;
}

.upload-zone.compact {
  min-height: 90px;
  padding: 1.25rem;
  flex-direction: row;
  gap: 1rem;
}

.upload-zone.compact .uz-icon {
  width: 42px;
  height: 42px;
  font-size: 1.1rem;
  border-radius: 12px;
  margin: 0;
}

.uz-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-1);
}

.uz-sub {
  font-size: .83rem;
  color: var(--text-3);
}

.uz-badge {
  margin-top: .25rem;
  font-size: .75rem;
  color: var(--primary);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: .35rem;
}

/* =============================================================
   Image Grid
   ============================================================= */
.image-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(185px, 1fr));
  gap: 1rem;
}

.image-card {
  background: var(--surface);
  backdrop-filter: blur(16px);
  border-radius: var(--radius-lg);
  border: 1px solid rgba(0, 0, 0, 0.03);
  /* Almost invisible border */
  overflow: hidden;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.02);
  /* Ultra-soft base shadow */
  position: relative;
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.image-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.04);
  /* Deeper but extremely diffuse hover shadow */
  border-color: rgba(45, 90, 84, 0.1);
}

.card-thumb {
  width: 100%;
  height: 200px;
  /* More vertical breathing room */
  background: #fdfdfd;
  /* Clean, near-white background */
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
  transition: background 0.4s ease;
}


.card-thumb img {
  max-width: 80%;
  /* More padding for a 'museum' look */
  max-height: 80%;
  object-fit: contain;
  filter: drop-shadow(0 15px 35px rgba(0, 0, 0, 0.04));
  /* Extremely soft photo shadow */
  transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.image-card:hover .card-thumb img {
  transform: scale(1.05);
}

.card-body {
  padding: .75rem .85rem;
}

.card-name {
  font-size: .78rem;
  font-weight: 500;
  /* Lighter weight for cleanliness */
  color: var(--text-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: .25rem;
  letter-spacing: -0.01em;
}

.card-meta {
  font-size: .72rem;
  color: var(--text-3);
  display: flex;
  justify-content: space-between;
}

/* Card action overlay — bottom gradient */
.card-actions {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: .35rem;
  padding: .5rem .6rem;
  background: linear-gradient(to top, rgba(0, 0, 0, .6) 0%, transparent 100%);
  opacity: 0;
  transition: opacity var(--transition);
  pointer-events: none;
}

.image-card:hover .card-actions {
  opacity: 1;
  pointer-events: all;
}

.card-btn {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .7rem;
  color: #fff;
  border: none;
  cursor: pointer;
  transition: transform var(--transition), filter var(--transition);
}

.card-btn:hover {
  transform: scale(1.15);
  filter: brightness(1.2);
}

.card-btn.dl {
  background: rgba(91, 80, 232, .9);
}

.card-btn.rm {
  background: rgba(239, 68, 68, .85);
}

/* Card states */
@keyframes cardPulse {

  0%,
  100% {
    opacity: 1
  }

  50% {
    opacity: .45
  }
}

.image-card.processing {
  animation: cardPulse .75s ease infinite;
  border-color: var(--primary);
}

@keyframes cardDone {
  0% {
    box-shadow: 0 0 0 0 rgba(16, 185, 129, .65);
    border-color: var(--success);
  }

  70% {
    box-shadow: 0 0 0 10px rgba(16, 185, 129, 0);
  }

  100% {
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
    border-color: var(--border);
  }
}

.image-card.done {
  animation: cardDone .7s ease forwards;
}

/* =============================================================
   Processing Overlay
   ============================================================= */
#progressOverlay {
  position: fixed;
  inset: 0;
  z-index: 300;
  background: var(--glass-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
}

#progressOverlay.visible {
  opacity: 1;
  pointer-events: all;
}

.progress-modal {
  background: var(--surface);
  backdrop-filter: blur(24px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-xl);
  padding: 2.5rem 3rem;
  width: 360px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
  box-shadow: var(--shadow-lg);
  animation: popIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes popIn {
  from {
    transform: scale(.92);
    opacity: 0;
  }

  to {
    transform: scale(1);
    opacity: 1;
  }
}

.progress-spinner {
  width: 52px;
  height: 52px;
  border: 4px solid var(--border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin .75s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.progress-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-1);
}

.progress-sub {
  font-size: .83rem;
  color: var(--text-2);
}

.progress-bar-track {
  width: 100%;
  height: 7px;
  background: var(--surface-2);
  border-radius: 999px;
  overflow: hidden;
}

.progress-bar-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--primary), #8B5CF6);
  border-radius: 999px;
  transition: width .3s ease;
}

/* =============================================================
   Content Pages (Blog, About, etc.)
   ============================================================= */
.page-wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 3.5rem 2rem;
  flex: 1;
}

.prose {
  max-width: 780px;
}

/* --- Pro Features --- */
.glass-panel {
  background: var(--glass-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--glass-shadow);
}

.preset-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.65rem;
  margin-top: 0.5rem;
}

.btn-preset {
  padding: 0.75rem 0.5rem;
  font-size: 0.75rem;
  background: var(--surface-solid);
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--text-2);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  transition: all var(--transition);
}

.btn-preset:hover {
  background: var(--primary-light);
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-3px);
  box-shadow: var(--shadow-sm);
}

.btn-preset i {
  font-size: 1.1rem;
}

.estimation-badge {
  font-size: 0.72rem;
  padding: 0.3rem 0.65rem;
  background: var(--primary-light);
  color: var(--primary);
  border-radius: 999px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
}

.prose h1 {
  font-size: 2.25rem;
  font-weight: 800;
  margin-bottom: 1.25rem;
  letter-spacing: -.02em;
}

.prose h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 2rem 0 .75rem;
  color: var(--text-1);
}

.prose p {
  color: var(--text-2);
  line-height: 1.8;
  margin-bottom: 1.1rem;
}

.prose ul,
.prose ol {
  color: var(--text-2);
  padding-left: 1.5rem;
  margin-bottom: 1.1rem;
}

.prose li {
  margin-bottom: .45rem;
}

/* Blog Grid */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 1.5rem;
}

.blog-card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  border: 1.5px solid var(--border);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform .2s ease, box-shadow .2s ease;
}

.blog-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.blog-card-img {
  width: 100%;
  height: 185px;
  object-fit: cover;
  background: var(--surface-2);
}

.blog-card-body {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.blog-card-cat {
  font-size: .68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  margin-bottom: .5rem;
}

.blog-card-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-1);
  margin-bottom: .5rem;
  line-height: 1.4;
}

.blog-card-date {
  font-size: .72rem;
  color: var(--text-3);
  margin-bottom: .75rem;
}

.blog-card-excerpt {
  font-size: .83rem;
  color: var(--text-2);
  flex: 1;
  margin-bottom: 1rem;
  line-height: 1.6;
}

.blog-card-link {
  font-size: .83rem;
  font-weight: 700;
  color: var(--primary);
  display: inline-flex;
  align-items: center;
  gap: .3rem;
}

.blog-card-link i {
  transition: transform .2s;
}

.blog-card:hover .blog-card-link i {
  transform: translateX(4px);
}

/* =============================================================
   Footer
   ============================================================= */
.footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 2rem 2rem;
  text-align: center;
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.footer-nav {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  justify-content: center;
}

.footer-nav a {
  font-size: .83rem;
  color: var(--text-2);
  transition: color var(--transition);
}

.footer-nav a:hover {
  color: var(--primary);
}

.footer-copy {
  font-size: .78rem;
  color: var(--text-3);
}

/* =============================================================
   Post Body
   ============================================================= */
.post-body h2 {
  font-size: 1.4rem;
  font-weight: 700;
  margin: 2rem 0 .75rem;
  color: var(--text-1);
}

.post-body p {
  color: var(--text-2);
  line-height: 1.85;
  margin-bottom: 1.1rem;
}

/* =============================================================
   Responsive
   ============================================================= */
@media (max-width: 900px) {
  :root {
    --sidebar-w: 100%;
  }

  .nav-center,
  .nav-right {
    display: none;
  }

  .menu-toggle {
    display: flex;
  }

  .workspace {
    flex-direction: column;
    height: auto;
    overflow-y: visible;
  }

  .sidebar {
    width: 100%;
    border-right: none;
    border-bottom: 1px solid var(--glass-border);
    backdrop-filter: none;
    /* Reduce blur on mobile for perf */
  }

  .canvas-area {
    padding: 1rem;
    overflow-y: visible;
  }

  .canvas-toolbar {
    flex-direction: column;
    align-items: flex-start;
  }

  .preset-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .dim-row {
    grid-template-columns: 1fr;
  }
}

/* =============================================================
   Utilities
   ============================================================= */
.hidden {
  display: none !important;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}