/* ══════════════════════════════════════════════════════
   IZGE — Global Stylesheet
   ══════════════════════════════════════════════════════ */

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --bg: #0b0c10;
  --bg-2: #0f1117;
  --bg-3: #14171f;
  --border: rgba(255, 255, 255, 0.07);
  --border-hover: rgba(255, 255, 255, 0.14);
  --accent: #4fd1c5;
  --accent-dark: #38b2ac;
  --accent-dim: rgba(79, 209, 197, 0.1);
  --accent-glow: rgba(79, 209, 197, 0.18);
  --text: #f0f2f5;
  --text-muted: #5a6475;
  --text-soft: #8b95a5;
  --glass-bg: rgba(255, 255, 255, 0.03);
  --glass-border: rgba(255, 255, 255, 0.08);
  --radius-sm: 8px;
  --radius: 12px;
  --radius-lg: 18px;
  --radius-xl: 24px;
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
  --shadow-sm: 0 2px 12px rgba(0, 0, 0, 0.3);
  --t: 0.2s ease;
  --font: "Inter", system-ui, -apple-system, sans-serif;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.6;
  overflow-x: hidden; /* Prevent horizontal scroll on mobile */
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: var(--accent);
  text-decoration: none;
}
img {
  max-width: 100%;
  display: block;
}
button {
  font-family: var(--font);
}

/* ── UTILITIES ──────────────────────────────────────── */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

/* ── GLASSMORPHISM ──────────────────────────────────── */
.glass {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

/* ══════════════════════════════════════════════════════
   BUTTONS
   ══════════════════════════════════════════════════════ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.7rem 1.6rem;
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all var(--t);
  white-space: nowrap;
  text-decoration: none;
  letter-spacing: 0.01em;
}
.btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
  pointer-events: none;
}
.btn:not(:disabled):active {
  transform: scale(0.97);
}

.btn-primary {
  background: var(--accent);
  color: #0a0e12;
  font-weight: 700;
}
.btn-primary:hover {
  background: var(--accent-dark);
  color: #0a0e12;
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.09);
  border-color: var(--border-hover);
  color: var(--text);
}

.btn-sm {
  padding: 0.45rem 1rem;
  font-size: 0.82rem;
}
.btn-lg {
  padding: 0.85rem 2rem;
  font-size: 1rem;
}
.btn-full {
  width: 100%;
}
.btn-icon {
  padding: 0.6rem;
  border-radius: var(--radius-sm);
}

/* ══════════════════════════════════════════════════════
   NAVBAR
   ══════════════════════════════════════════════════════ */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 62px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 3vw;
  background: rgba(10, 10, 10, 0.82);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  z-index: 10000;
  pointer-events: auto;
  transition: background 0.3s ease;
}

.nav-content {
  max-width: 100%;
  margin: 0 auto;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-size: 1.4rem;
  font-weight: 900;
  letter-spacing: 0.14em;
  color: var(--text);
  text-transform: uppercase;
  transition: opacity var(--t);
}
.nav-logo:hover {
  opacity: 0.75;
  color: var(--text);
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Dropdown */
.dropdown {
  position: relative;
  display: inline-block;
}

.btn-account {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0.9rem 0.45rem 0.6rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-soft);
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--t);
}
.btn-account:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
}
.btn-account:focus {
  outline: none;
}

/* Klasör Görünümü Stilleri */
.archive-explorer {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 0.5rem;
}

/* MODERN FILE MANAGER UI */
.folder-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 1.25rem;
  padding: 1rem 0;
}

.folder-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  text-align: center;
  overflow: hidden;
}

.folder-card:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: var(--accent);
  transform: translateY(-4px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.folder-card.selected {
  border-color: var(--accent);
  background: var(--accent-dim);
}

.folder-card .folder-icon {
  width: 48px;
  height: 48px;
  color: #f59e0b;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
}

.folder-card .folder-name {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-soft);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  width: 100%;
}

.folder-card:hover .folder-name {
  color: #fff;
}

.folder-card .folder-check {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 5;
  opacity: 0.5;
  transition: opacity 0.2s;
}
.folder-card:hover .folder-check,
.folder-card.selected .folder-check {
  opacity: 1;
}

.archive-nav-bar {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.8rem 0;
  margin-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}

.archive-path-display {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-soft);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.archive-path-display span {
  color: var(--accent);
}

.btn-back {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text-soft);
  cursor: pointer;
  transition: all 0.2s;
}

.btn-back:hover {
  background: var(--accent-dim);
  color: var(--accent);
  border-color: var(--accent);
}

/* Folder & Content display */
.folder-content,
.date-content,
.scan-content {
  display: none;
  padding: 0.8rem;
  background: var(--bg-1);
  border-top: 1px solid var(--border);
}
.user-folder.open > .folder-content,
.date-folder.open > .date-content,
.scan-folder.open > .scan-content {
  display: block;
}

/* Chevron Rotation */
.open > .monolith-header .chevron,
.open > .folder-header .chevron {
  transform: rotate(180deg);
}

.user-folder,
.date-folder {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 0.5rem;
  transition: all 0.2s;
}

/* Monolith Header Style */
.monolith-header {
  background: var(--bg-3) !important;
  border: 1px solid var(--glass-border) !important;
  border-left: 4px solid var(--accent) !important;
  padding: 0.75rem 1rem !important;
  border-radius: var(--radius) !important;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.5rem;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  position: relative;
  z-index: 5;
}
.monolith-header:hover {
  background: var(--bg-2) !important;
  border-color: var(--accent) !important;
  transform: translateX(4px);
}
.monolith-header.secondary {
  border-left-color: var(--text-muted) !important;
  background: rgba(255, 255, 255, 0.03) !important;
  margin-top: 1.5rem;
}
.monolith-header.secondary:hover {
  border-left-color: var(--accent);
}

.folder-title {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  flex: 1;
  color: var(--text);
  font-weight: 700;
  letter-spacing: 0.02em;
}
.folder-title span {
  font-size: 0.95rem;
}
.folder-title svg {
  color: var(--accent);
}

.header-actions {
  display: flex;
  gap: 0.6rem;
  align-items: center;
}

/* Action Pills */
.btn-action-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.9rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  border-radius: 50px;
  color: var(--text-soft);
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-action-pill:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text);
  border-color: var(--border-hover);
}
.btn-action-pill svg {
  opacity: 0.8;
}

.btn-action-pill.btn-3d-generate {
  background: rgba(79, 209, 197, 0.1);
  color: var(--accent);
  border-color: rgba(79, 209, 197, 0.3);
}
.btn-action-pill.btn-3d-generate:hover {
  background: var(--accent);
  color: #000;
}

.btn-action-pill.btn-danger {
  color: #ff4757;
  background: rgba(255, 71, 87, 0.05);
  border-color: rgba(255, 71, 87, 0.2);
}
.btn-action-pill.btn-danger:hover {
  background: #ff4757;
  color: white;
}

/* Loading State Refinement */
.btn-loading {
  position: relative;
  pointer-events: none;
  opacity: 0.8 !important;
  color: transparent !important;
}
.btn-loading svg {
  visibility: hidden;
}
.btn-loading::after {
  content: "";
  position: absolute;
  width: 16px;
  height: 16px;
  top: calc(50% - 8px);
  left: calc(50% - 8px);
  border: 2px solid rgba(255, 255, 255, 0.2);
  border-top-color: currentColor;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
.btn-loading.btn-3d-generate::after {
  border-top-color: var(--accent);
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Folder Glow Effect */
.date-folder,
.scan-folder {
  transition: all 0.3s ease;
}
.date-folder.has-selection,
.scan-folder.has-selection,
.scan-sub-group.has-selection {
  box-shadow: 0 0 20px rgba(79, 209, 197, 0.15);
  border-color: var(--accent-glow);
}

.scan-folder,
.scan-sub-group {
  margin-bottom: 2rem;
  background: rgba(255, 255, 255, 0.015);
  padding: 1.2rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
}
.scan-folder:last-child,
.scan-sub-group:last-child {
  margin-bottom: 0;
}

/* Status Indicators with Pulse */
.status-indicator {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.status-ready {
  background: rgba(79, 209, 197, 0.1);
  color: var(--accent);
}
.status-processing {
  background: rgba(255, 171, 0, 0.1);
  color: #ffab00;
  border: 1px solid rgba(255, 171, 0, 0.2);
  animation: pulseSoft 2s infinite ease-in-out;
}
.status-done {
  background: rgba(56, 217, 185, 0.1);
  color: #38d9b9;
}
.status-failed {
  background: rgba(255, 71, 87, 0.1);
  color: #ff4757;
}

@keyframes pulseSoft {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.5;
    transform: scale(0.96);
  }
}

.photo-grid-mini {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
  gap: 12px;
}
.photo-item-box {
  position: relative;
  aspect-ratio: 1;
  border-radius: 8px;
  overflow: hidden;
  border: 2px solid var(--border);
  background: #000;
  cursor: pointer;
  transition: all 0.2s;
}
.photo-item-box.selected {
  border-color: var(--accent);
  box-shadow: 0 0 15px rgba(79, 209, 197, 0.3);
}

/* Checkbox Style */
.photo-check {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 10;
  width: 24px;
  height: 24px;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.6);
  border: 2px solid rgba(255, 255, 255, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  cursor: pointer;
}
.photo-item-box:hover .photo-check {
  border-color: white;
  background: rgba(0, 0, 0, 0.8);
}
.photo-item-box.selected .photo-check {
  background: var(--accent);
  border-color: var(--accent);
}
.bulk-check {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  width: 100%;
  height: 100%;
  margin: 0;
  z-index: 11;
}
.photo-item-box.selected .photo-check::after {
  content: "";
  width: 6px;
  height: 10px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
  margin-top: -2px;
}

/* Floating Action Bar */
.selection-bar {
  position: fixed;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  background: var(--bg-2);
  border: 1px solid var(--border);
  padding: 0.8rem 1.5rem;
  border-radius: 50px;
  display: flex;
  align-items: center;
  gap: 2rem;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.8);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  z-index: 3000;
  opacity: 0;
  backdrop-filter: blur(15px);
}
.selection-bar.active {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}
.selection-info {
  color: var(--text);
  font-weight: 600;
  font-size: 0.95rem;
}
.selection-actions {
  display: flex;
  gap: 0.8rem;
}
.btn-clear {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-soft);
  padding: 0.6rem 1.2rem;
  border-radius: 25px;
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 500;
}
.btn-clear:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
}
.btn-bulk-del {
  background: #ef4444;
  border: none;
  color: white;
  padding: 0.6rem 1.5rem;
  border-radius: 25px;
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 700;
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}
.btn-bulk-del:hover {
  background: #dc2626;
  transform: scale(1.02);
}

/* Dashboard Archive Specifics */
.user-archive-section .archive-explorer {
  padding: 0;
  border: none;
  background: transparent;
}
.user-archive-section .date-folder {
  background: rgba(255, 255, 255, 0.02);
  border-color: var(--border);
}
.user-archive-section .monolith-header {
  margin-bottom: 1rem;
}
.user-archive-section .monolith-header.secondary {
  margin-top: 2rem;
  margin-bottom: 1rem;
}
.archive-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.archive-title h3 {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text);
}
.archive-title svg {
  color: var(--accent);
  opacity: 0.9;
}

.btn-account .avatar-mini {
  width: 26px;
  height: 26px;
  background: var(--accent-dim);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--accent);
  border: 1px solid rgba(79, 209, 197, 0.2);
  overflow: hidden;
}

.chevron {
  transition: transform var(--t);
}
.dropdown:hover .chevron {
  transform: rotate(180deg);
}

.dropdown-menu {
  display: none;
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  min-width: 220px;
  width: max-content;
  max-width: 90vw; /* Prevent menu overflow on tiny screens */
  z-index: 10001;
  transform-origin: top right;
  pointer-events: auto !important;
}

.dropdown-menu::before {
  content: "";
  position: absolute;
  top: -8px;
  right: 0;
  left: 0;
  height: 8px;
  background: transparent;
}

.dropdown-inner {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  animation: dropIn 0.15s ease;
}
@keyframes dropIn {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.dropdown.active .dropdown-menu,
.dropdown:hover .dropdown-menu {
  display: block;
}

.drop-item {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.65rem 1rem;
  color: var(--text-soft);
  font-size: 0.875rem;
  transition: all var(--t);
}
.drop-item:hover {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
}
.drop-item svg {
  flex-shrink: 0;
  opacity: 0.7;
}
.drop-item.danger:hover {
  color: #f87171;
  background: rgba(248, 113, 113, 0.05);
}
.drop-divider {
  height: 1px;
  background: var(--border);
  margin: 4px 0;
}

/* ══════════════════════════════════════════════════════
   SECTION LABELS
   ══════════════════════════════════════════════════════ */
.eyebrow {
  display: inline-block;
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  color: var(--accent);
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.section-title {
  font-size: clamp(1.9rem, 3.5vw, 2.8rem);
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.15;
  margin-bottom: 0.75rem;
}

.section-sub {
  color: var(--text-soft);
  font-size: 1rem;
  max-width: 540px;
  line-height: 1.75;
}

/* ══════════════════════════════════════════════════════
   HERO — TAM ORTALI + PARTİKÜL ARKA PLAN
   ══════════════════════════════════════════════════════ */
.hero {
  position: relative;
  min-height: calc(100vh - 62px);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 5rem 2rem;
  text-align: center;
}

#particleCanvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

.hero-inner {
  position: relative;
  z-index: 2;
  max-width: 740px;
  margin: 0 auto;
}

.hero-title {
  font-size: clamp(2.4rem, 10vw, 7rem);
  font-weight: 900;
  line-height: 0.93;
  letter-spacing: -0.03em;
  color: var(--text);
  margin-bottom: 1.8rem;
}
.hero-title span {
  color: var(--accent);
  white-space: nowrap;
}

.hero-desc {
  font-size: 1.1rem;
  color: var(--text-soft);
  max-width: 520px;
  margin: 0 auto 2.8rem;
  line-height: 1.75;
}

.hero-cta {
  display: flex;
  gap: 0.8rem;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
}

/* ── HERO STATS ───────────────────────────────────────── */
.hero-stats {
  display: flex;
  gap: 0;
  margin-top: 3.5rem;
  flex-wrap: wrap;
  justify-content: center;
}
.hero-stats > div {
  position: relative;
  padding: 0 2.5rem;
  margin-bottom: 1rem;
}
.hero-stats > div:not(:last-child)::after {
  content: "";
  position: absolute;
  right: 0;
  top: 15%;
  height: 70%;
  width: 1px;
  background: var(--border);
}
.hero-stat-num {
  font-size: 2rem;
  font-weight: 900;
  color: var(--text);
  line-height: 1;
}
.hero-stat-lbl {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 0.28rem;
  text-transform: uppercase;
  letter-spacing: 0.09em;
}

/* ── Desktop-only hero title offset ─────────────────── */
@media (min-width: 768px) {
  .hero-title-1 {
    display: inline-block;
    margin-left: -50px;
  }
}

/* ── METIN REVEAL ───────────────────────────────────── */
.reveal-line,
.reveal-item {
  opacity: 0;
  transform: translateY(28px);
}
.do-reveal {
  animation: revealUp 0.75s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  animation-delay: var(--d, 0s);
}
@keyframes revealUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.accent-line {
  color: var(--accent);
}

/* ── SHINE BUTTON ───────────────────────────────────── */
.btn-shine {
  position: relative;
  overflow: hidden;
}
.btn-shine::after {
  content: "";
  position: absolute;
  top: -50%;
  left: -75%;
  width: 50%;
  height: 200%;
  background: rgba(255, 255, 255, 0.18);
  transform: skewX(-20deg);
  transition: left 0.55s ease;
}
.btn-shine:hover::after {
  left: 125%;
}

/* ── SCROLL HINT ────────────────────────────────────── */
.scroll-hint {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  margin-top: 3rem;
  color: var(--text-muted);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.scroll-mouse {
  width: 22px;
  height: 36px;
  border: 1.5px solid rgba(255, 255, 255, 0.15);
  border-radius: 999px;
  display: flex;
  justify-content: center;
  padding-top: 6px;
}
.scroll-dot {
  width: 4px;
  height: 4px;
  background: var(--accent);
  border-radius: 50%;
  animation: scrollBounce 1.8s ease-in-out infinite;
}
@keyframes scrollBounce {
  0%,
  100% {
    transform: translateY(0);
    opacity: 1;
  }
  60% {
    transform: translateY(10px);
    opacity: 0.3;
  }
}

/* ══════════════════════════════════════════════════════
   INDEX — VISION
   ══════════════════════════════════════════════════════ */
.section {
  padding: 7rem 0;
}
.section-center {
  text-align: center;
}
.section-center .section-sub {
  margin: 0 auto;
}

.vision-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.2rem;
  margin-top: 3.5rem;
}

.v-card {
  padding: 2rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--glass-bg);
  transition:
    border-color var(--t),
    transform var(--t);
  cursor: default;
}
.v-card:hover {
  border-color: rgba(79, 209, 197, 0.2);
  transform: translateY(-2px);
}
.v-card.featured {
  border-color: rgba(79, 209, 197, 0.22);
  background: rgba(79, 209, 197, 0.03);
}

.v-card-icon {
  width: 48px;
  height: 48px;
  background: var(--accent-dim);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  margin-bottom: 1.2rem;
}
.v-card-icon svg {
  width: 22px;
  height: 22px;
}
.v-card h3 {
  font-size: 1.05rem;
  font-weight: 650;
  margin-bottom: 0.6rem;
}
.v-card p {
  color: var(--text-soft);
  font-size: 0.875rem;
  line-height: 1.75;
}

/* ── QUOTE BLOCK ──────────────────────────────────────── */
.quote-block {
  margin: 4rem auto 0;
  max-width: 700px;
  padding: 2.5rem 3rem;
  border-left: 3px solid var(--accent);
  background: var(--glass-bg);
  border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
}
.quote-text {
  font-size: 1.25rem;
  font-weight: 300;
  line-height: 1.75;
  color: var(--text-soft);
  font-style: italic;
}
.quote-text strong {
  color: var(--text);
  font-weight: 600;
  font-style: normal;
}

/* ══════════════════════════════════════════════════════
   INDEX — STEPS
   ══════════════════════════════════════════════════════ */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 2rem;
  margin-top: 3.5rem;
  position: relative;
}

.step-card {
  padding: 2rem 1.8rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--glass-bg);
  position: relative;
  overflow: hidden;
}
.step-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(79, 209, 197, 0.25),
    transparent
  );
}

.step-num {
  font-size: 3rem;
  font-weight: 900;
  color: var(--accent);
  opacity: 0.15;
  line-height: 1;
  margin-bottom: 1rem;
}
.step-card h4 {
  font-size: 1rem;
  font-weight: 650;
  margin-bottom: 0.5rem;
}
.step-card p {
  color: var(--text-soft);
  font-size: 0.85rem;
  line-height: 1.7;
}

/* ══════════════════════════════════════════════════════
   INDEX — PRICING
   ══════════════════════════════════════════════════════ */
.price-features li.off .fi {
  color: var(--text-muted);
}

/* ── MODERN VERTICAL MONOLITH PRICING ── */
.pricing-grid {
  display: flex;
  justify-content: center;
  align-items: stretch;
  gap: 1.5rem;
  margin-top: 4rem;
  flex-wrap: wrap; /* Allow wrapping on all screens if needed, but flex-basis controls desktop */
  perspective: 2000px;
  width: 100%;
}

.price-card {
  flex: 1 1 280px; /* Allow shrinking/growing with a base size */
  min-width: 280px;
  max-width: 320px;
  padding: 3rem 1.5rem;
  background: rgba(255, 255, 255, 0.015);
  border: 1px solid rgba(255, 255, 255, 0.08); /* Slightly more visible */
  border-radius: var(--radius-xl);
  display: flex;
  flex-direction: column;
  text-align: left;
  min-height: 480px; /* Her kart aynı boyda dursun */
  transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
  position: relative;
  overflow: hidden;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: inset 0 0 20px rgba(255, 255, 255, 0.02); /* Dual layer effect */
}

/* Vertical Accent Line */
.price-card::after {
  content: "";
  position: absolute;
  left: 0;
  top: 20%;
  bottom: 20%;
  width: 2px;
  background: linear-gradient(
    to bottom,
    transparent,
    rgba(255, 255, 255, 0.1),
    transparent
  );
  transition: all 0.5s ease;
}

.price-card:hover {
  transform: translateY(-15px) rotateY(2deg);
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.5);
}

.price-card:hover::after {
  background: var(--accent);
  box-shadow: 0 0 15px var(--accent);
}

.price-card.featured {
  background: linear-gradient(
    180deg,
    rgba(79, 209, 197, 0.06) 0%,
    rgba(10, 10, 10, 0.2) 100%
  );
  border-color: rgba(79, 209, 197, 0.3);
  border-top: 1px solid rgba(79, 209, 197, 0.6);
  animation: verticalPulse 4s infinite ease-in-out;
  box-shadow:
    0 20px 50px rgba(0, 0, 0, 0.5),
    0 0 20px rgba(79, 209, 197, 0.05);
}

.price-card.featured::after {
  background: linear-gradient(
    to bottom,
    transparent,
    var(--accent),
    transparent
  );
  width: 3px;
  opacity: 0.8;
}

@keyframes verticalPulse {
  0%,
  100% {
    box-shadow:
      0 20px 50px rgba(0, 0, 0, 0.5),
      0 0 20px rgba(79, 209, 197, 0.05);
    border-color: rgba(79, 209, 197, 0.3);
  }
  50% {
    box-shadow:
      0 20px 50px rgba(0, 0, 0, 0.6),
      0 0 40px rgba(79, 209, 197, 0.15);
    border-color: rgba(79, 209, 197, 0.6);
  }
}

.price-badge {
  position: absolute;
  top: 20px;
  right: -30px;
  transform: rotate(45deg);
  background: var(--accent);
  color: #000;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 6px 40px;
  text-transform: uppercase;
  letter-spacing: 1px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

.price-plan {
  font-size: 0.8rem;
  font-weight: 800;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 4px;
  margin-bottom: 0.8rem;
  opacity: 0.9;
}

.price-value {
  font-size: 3.5rem;
  font-weight: 900;
  margin-bottom: 0.2rem;
  display: flex;
  align-items: baseline;
  gap: 0.4rem;
}
.price-value span {
  font-size: 1.1rem;
  color: var(--text-muted);
  font-weight: 500;
}

.price-desc {
  font-size: 0.9rem;
  color: var(--text-soft);
  line-height: 1.6;
  margin-bottom: 2rem;
}

.price-add-info {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--accent);
  letter-spacing: 0.05em;
  margin-bottom: 1rem;
  opacity: 0.8;
}

.price-features {
  margin-top: auto;
  margin-bottom: 2.5rem;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.price-features li {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  font-size: 0.95rem;
  color: var(--text-soft);
  transition: transform 0.2s;
}
.price-card:hover .price-features li {
  transform: translateX(5px);
}

.price-features svg {
  flex-shrink: 0;
}
.price-features li.off {
  opacity: 0.25;
}

.btn-price {
  margin-top: auto;
  width: 100%;
  padding: 1rem;
  border-radius: 14px;
  font-size: 1rem;
  font-weight: 700;
}

/* ── PROFILE ENHANCEMENTS ── */
.color-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 0.5rem;
}

.color-dot {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  border: 2px solid transparent;
  transition: all 0.2s;
  position: relative;
}

.color-dot:hover {
  transform: scale(1.15);
}

.color-dot.active {
  border-color: #fff;
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
}

.color-dot.custom-trigger {
  background: conic-gradient(
    from 0deg,
    red,
    yellow,
    lime,
    aqua,
    blue,
    magenta,
    red
  );
}

#customColorInput {
  opacity: 0;
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  cursor: pointer;
}

/* ══════════════════════════════════════════════════════
   FOOTER
   ══════════════════════════════════════════════════════ */
.footer {
  padding: 2.5rem 0;
  border-top: 1px solid var(--border);
  margin-top: auto;
}
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}
.footer-logo {
  font-size: 1.1rem;
  font-weight: 900;
  letter-spacing: 0.14em;
  color: var(--text);
}
.footer-copy {
  font-size: 0.82rem;
  color: var(--text-muted);
}
.footer-links {
  display: flex;
  gap: 1.5rem;
}
.footer-links a {
  font-size: 0.82rem;
  color: var(--text-muted);
  transition: color var(--t);
}
.footer-links a:hover {
  color: var(--text);
}

/* ══════════════════════════════════════════════════════
   AUTH PAGES
   ══════════════════════════════════════════════════════ */
.page-auth {
  background: #080808;
  position: relative;
  overflow-x: hidden;
}
.page-auth::before {
  content: "";
  position: fixed;
  top: -10%;
  right: -10%;
  width: 600px;
  height: 600px;
  background: radial-gradient(
    circle,
    rgba(79, 209, 197, 0.07) 0%,
    transparent 70%
  );
  z-index: -1;
  pointer-events: none;
}
.page-auth::after {
  content: "";
  position: fixed;
  bottom: -10%;
  left: -10%;
  width: 500px;
  height: 500px;
  background: radial-gradient(
    circle,
    rgba(128, 90, 213, 0.05) 0%,
    transparent 70%
  );
  z-index: -1;
  pointer-events: none;
}
.auth-bg-decor {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: -1;
  pointer-events: none;
  opacity: 0.4;
  filter: blur(40px);
}

.auth-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 62px);
  padding: 2rem 1rem;
  margin-top: 62px;
}

.auth-card {
  width: 100%;
  max-width: 430px;
  padding: 2.8rem 2.4rem;
}

.auth-logo-row {
  text-align: center;
  margin-bottom: 2.5rem;
}
.auth-logo {
  font-size: 1.5rem;
  font-weight: 900;
  letter-spacing: 0.14em;
  color: var(--text);
}
.auth-logo-sub {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-top: 0.3rem;
}

.auth-heading {
  font-size: 1.55rem;
  font-weight: 800;
  margin-bottom: 0.3rem;
}
.auth-sub {
  font-size: 0.875rem;
  color: var(--text-soft);
  margin-bottom: 2rem;
}

/* FORM */
.form-group {
  margin-bottom: 1.1rem;
}

label.form-label {
  display: block;
  font-size: 0.8rem;
  color: var(--text-soft);
  font-weight: 500;
  margin-bottom: 0.4rem;
  letter-spacing: 0.02em;
}

.form-input {
  width: 100%;
  padding: 0.72rem 1rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-size: 0.9rem;
  font-family: var(--font);
  outline: none;
  transition:
    border-color var(--t),
    background var(--t);
}
.form-input::placeholder {
  color: var(--text-muted);
}
.form-input:focus {
  border-color: rgba(79, 209, 197, 0.45);
  background: rgba(79, 209, 197, 0.025);
}

.input-row {
  position: relative;
}
.input-row .form-input {
  padding-right: 2.8rem;
}

.toggle-pw {
  position: absolute;
  right: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0;
  line-height: 0;
  transition: color var(--t);
}
.toggle-pw:hover {
  color: var(--text-soft);
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  margin: 1.5rem 0;
  color: var(--text-muted);
  font-size: 0.75rem;
}
.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}

.auth-switch {
  text-align: center;
  margin-top: 1.4rem;
  font-size: 0.85rem;
  color: var(--text-muted);
}
.auth-switch a {
  color: var(--accent);
  font-weight: 500;
}

/* ALERTS */
.alert {
  padding: 0.72rem 1rem;
  border-radius: var(--radius);
  font-size: 0.85rem;
  margin-bottom: 1.2rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.alert-error {
  background: rgba(248, 113, 113, 0.08);
  border: 1px solid rgba(248, 113, 113, 0.2);
  color: #fca5a5;
}
.alert-success {
  background: rgba(79, 209, 197, 0.07);
  border: 1px solid rgba(79, 209, 197, 0.2);
  color: var(--accent);
}

/* BADGES */
.plan-pill {
  display: inline-block;
  padding: 0.18rem 0.65rem;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.plan-free {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-muted);
}
.plan-pro {
  background: rgba(79, 209, 197, 0.12);
  color: var(--accent);
}
.plan-ent {
  background: rgba(251, 191, 36, 0.12);
  color: #fbbf24;
}
.plan-admin {
  background: rgba(167, 139, 250, 0.1);
  color: #c4b5fd;
}

/* ══════════════════════════════════════════════════════
   DASHBOARD
   ══════════════════════════════════════════════════════ */
.dash-layout {
  display: flex;
  height: calc(100vh - 62px);
  overflow: hidden;
  margin-top: 62px;
}

/* SIDEBAR */
.dash-sidebar {
  width: 285px;
  flex-shrink: 0;
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  background: var(--bg-2);
  padding: 1.25rem;
}

/* SIDEBAR USER CARD (New Flex Layout) */
.sidebar-user-card {
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 1.5rem;
}
.user-row {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}
.user-ava {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  font-weight: 800;
  color: #000;
}
.user-meta {
  min-width: 0;
}
.user-meta .user-name {
  font-weight: 700;
  font-size: 0.9rem;
  color: #fff;
  margin-bottom: 2px;
}
.user-plan-pill,
.plan-pill {
  font-size: 0.65rem;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 4px;
  display: inline-block;
  background: var(--accent-dim);
  color: var(--accent);
  text-transform: uppercase;
}
.plan-enterprise {
  background: rgba(251, 191, 36, 0.12);
  color: #fbbf24;
}
.plan-pro {
  background: rgba(167, 139, 250, 0.12);
  color: #a78bfa;
}
.plan-lite {
  background: rgba(79, 209, 197, 0.12);
  color: #4fd1c5;
}
.plan-free {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-muted);
}

.sidebar-stats-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: var(--border);
  border-radius: 8px;
  overflow: hidden;
}
.sidebar-stats-row .ss-item {
  background: var(--bg-1);
  padding: 0.8rem 0.5rem;
  text-align: center;
}
.ss-val {
  font-size: 1.2rem;
  font-weight: 900;
  color: var(--accent);
  line-height: 1;
}
.ss-lbl {
  font-size: 0.55rem;
  font-weight: 700;
  color: var(--text-muted);
  letter-spacing: 0.05em;
  margin-top: 2px;
}

.sidebar-section {
  padding: 1.2rem 1.5rem;
  border-bottom: 1px solid var(--border);
}
.sidebar-section:last-child {
  border-bottom: none;
  flex: 1;
}
.sidebar-title {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-bottom: 0.8rem;
}

.scan-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.scan-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 0.85rem;
  border-radius: var(--radius-sm);
  cursor: default;
  transition: all var(--t);
  min-height: 52px;
}
.scan-row:hover {
  background: rgba(255, 255, 255, 0.03);
}

.scan-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}
.dot-done {
  background: var(--accent);
}
.dot-processing {
  background: #fbbf24;
}
.dot-failed {
  background: #f87171;
}

.scan-row-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.scan-row-id {
  font-size: 0.75rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.scan-row-date {
  font-size: 0.65rem;
  color: var(--text-muted);
  white-space: nowrap;
}

.scan-status-pill {
  font-size: 0.5rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 0.15rem 0.4rem;
  border-radius: 999px;
  text-transform: uppercase;
  flex-shrink: 0;
  white-space: nowrap;
}
.pill-done, .pill-completed {
  background: rgba(79, 209, 197, 0.1);
  color: var(--accent);
}
.pill-processing {
  background: rgba(251, 191, 36, 0.1);
  color: #fbbf24;
}
.pill-failed {
  background: rgba(248, 113, 113, 0.1);
  color: #f87171;
}

.scan-row-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.btn-sidebar-view {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-soft);
  border-radius: 6px;
  width: 24px;
  height: 24px;
  min-width: 24px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
  padding: 0;
}

.btn-sidebar-view:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
}

.scan-empty {
  font-size: 0.82rem;
  color: var(--text-muted);
  text-align: center;
  padding: 1rem 0;
}

/* DASH MAIN & CAMERA CONTAINER */
.dash-main,
.cam-main {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  padding: 1.8rem 2rem;
  background: var(--bg);
  position: relative;
}

/* DASHBOARD HEADER (PURE FLEX) */
.dash-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  background: var(--bg-2);
  border-radius: var(--radius);
  margin-bottom: 2rem;
}
.dash-user-profile {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}
.dash-user-profile .user-details {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
.dash-user-profile .user-name {
  font-size: 1.1rem;
  font-weight: 800;
  color: #fff;
  line-height: 1;
}
.dash-stats {
  display: flex;
  gap: 2rem;
}
.dash-action-row {
  margin-top: 30px;
  margin-bottom: 2rem;
}

.btn-new-scan {
  padding: 0.6rem 1.25rem;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.85rem;
}

/* Mobile Scan Strip (Simple & Professional) */
.mobile-scan-strip {
  margin-bottom: 2rem;
}
.btn-scan-strip {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: var(--bg-2);
  border: 1px solid var(--border);
  padding: 1rem;
  border-radius: 16px;
  text-decoration: none;
  color: #fff;
  transition: background 0.2s;
}
.btn-scan-strip:active {
  background: var(--bg-3);
}
.bss-icon {
  width: 44px;
  height: 44px;
  background: var(--accent-dim);
  color: var(--accent);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.btn-scan-strip span {
  flex: 1;
  font-weight: 700;
  font-size: 0.95rem;
}

.mobile-only {
  display: none;
}
@media (max-width: 600px) {
  .mobile-only {
    display: flex;
  }
  .dash-header-right {
    display: none;
  } /* Hide the top button on mobile, use the card instead */
}

/* ══════════════════════════════════════════════════════
   DASHBOARD — TAM EKRAN KAMERA LAYOUT
   ══════════════════════════════════════════════════════ */

/* Body for dashboard pages */
.dash-body {
  overflow: hidden;
}

/* Fullscreen camera layout */
.dash-layout {
  display: flex;
  height: calc(100vh - 62px);
  overflow: hidden;
}

/* Sidebar — Sol taraf, sabit genişlik */
.dash-sidebar {
  width: 260px;
  flex-shrink: 0;
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  background: var(--bg-2);
  z-index: 10;
}

/* Main kamera alanı */
.cam-main {
  flex: 1;
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding: 0;
  gap: 0;
  background: #000;
}

/* Kamera kontrol bar'ı — üstte şeffaf overlay */
.cam-controls-bar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.8rem 1.2rem;
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.65) 0%,
    transparent 100%
  );
  backdrop-filter: none;
  gap: 1rem;
  flex-wrap: wrap;
}
.cam-controls-bar h2 {
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
  margin: 0;
}

/* CAMERA BOX — Esnek alan kaplar */
.camera-box {
  position: relative;
  flex: 1;
  min-height: 400px;
  border-radius: 12px;
  overflow: hidden;
  background: #000;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cam-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.8rem;
  color: var(--text-muted);
  font-size: 0.875rem;
}
.cam-placeholder svg {
  opacity: 0.18;
}

/* Base camera feed placeholder / layout info */
#cameraFeed {
  display: block !important;
}

/* ── MINIMALIST AR VIEWFINDER ── */
#boundingBox {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 280px;
  height: 280px;
  z-index: 10;
  cursor: move;
  touch-action: none;
  display: none;
  /* Focus / Vignette Effect */
  box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.65);
  border-radius: 4px;
}

/* Apple-style Corner Ticks */
.bb-c {
  position: absolute;
  width: 30px;
  height: 30px;
  border-color: #fff;
  border-style: solid;
  z-index: 20;
  border-radius: 2px;
}
.bb-tl {
  top: -2px;
  left: -2px;
  border-width: 4px 0 0 4px;
  cursor: nwse-resize;
}
.bb-tr {
  top: -2px;
  right: -2px;
  border-width: 4px 4px 0 0;
  cursor: nesw-resize;
}
.bb-bl {
  bottom: -2px;
  left: -2px;
  border-width: 0 0 4px 4px;
  cursor: nesw-resize;
}
.bb-br {
  bottom: -2px;
  right: -2px;
  border-width: 0 4px 4px 0;
  cursor: nwse-resize;
}

.bb-label {
  position: absolute;
  top: -40px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.85rem;
  color: #fff;
  white-space: nowrap;
  letter-spacing: 0.05em;
  font-weight: 500;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8);
  z-index: 20;
}

/* ── PROGRESS RING ── */
#progressRing {
  position: absolute;
  bottom: 40px;
  right: 20px;
  width: 90px;
  height: 90px;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 100;
  background: rgba(10, 15, 25, 0.7);
  border-radius: 50%;
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  animation: counterSlide 0.4s ease-out;
}
.p-ring {
  width: 80%;
  height: 80%;
  transform: rotate(-90deg);
}
.pr-bg {
  stroke: rgba(255, 255, 255, 0.1);
}
.pr-fill {
  stroke: var(--accent);
  stroke-linecap: round;
  transition: stroke-dashoffset 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}
.ring-inner {
  position: absolute;
  text-align: center;
  line-height: 1.1;
}
.ring-inner span {
  font-size: 1.2rem;
  font-weight: 900;
  color: #fff;
}
.ring-inner small {
  font-size: 0.6rem;
  color: var(--accent);
  display: block;
  font-weight: 700;
  text-transform: uppercase;
}

@keyframes counterSlide {
  from {
    transform: translateX(20px);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}
/* TOAST STATUS (Simple & Fixed) */
.status-toast {
  position: fixed;
  top: 80px;
  left: 50%;
  transform: translateX(-50%);
  padding: 0.8rem 1.5rem;
  border-radius: 12px;
  font-size: 0.9rem;
  font-weight: 700;
  z-index: 10000;
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  display: none;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
  white-space: nowrap;
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.s-info {
  background: rgba(30, 40, 60, 0.9);
  color: #fff;
}
.s-error {
  background: rgba(220, 38, 38, 0.9);
  color: #fff;
}
.s-warn {
  background: rgba(217, 119, 6, 0.9);
  color: #fff;
}

/* COMPLETE PANEL */
#completePanel {
  position: absolute;
  inset: 0;
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  text-align: center;
  padding: 2.5rem;
  background: rgba(10, 15, 25, 0.98); /* Opaque dark background */
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  z-index: 9999; /* Ensure it covers everything */
  border-radius: 12px;
}
#completePanel svg {
  color: var(--accent);
  width: 64px;
  height: 64px;
  margin-bottom: 0.5rem;
  filter: drop-shadow(0 0 15px var(--accent-glow));
}
#completePanel h3 {
  font-size: 1.8rem;
  font-weight: 800;
  color: #fff;
  margin: 0;
}
#completePanel p {
  color: var(--text-soft);
  font-size: 1rem;
  max-width: 280px;
  line-height: 1.5;
  margin-bottom: 1rem;
}
#completePanel .btn {
  box-shadow: 0 10px 30px rgba(79, 209, 197, 0.3);
}

/* ══════════════════════════════════════════════════════
   STANDALONE SCANNER PAGE (scan.php)
   ══════════════════════════════════════════════════════ */
.scan-page {
  background: #000;
  margin: 0;
  padding: 0;
  height: 100dvh;
  overflow: hidden;
  font-family: "Inter", sans-serif;
  color: #fff;
  -webkit-user-select: none;
  user-select: none;
}

.scan-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 80px;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: env(safe-area-inset-top) 1rem 0;
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0.8), transparent);
}

.btn-close-scan {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  opacity: 0.8;
  transition: opacity 0.2s;
}
.btn-close-scan:hover {
  opacity: 1;
}

.scan-mode-title {
  font-size: 0.9rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  opacity: 0.9;
}

.scanner-container {
  position: relative;
  width: 100%;
  height: 100%;
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
}

#cameraFeed {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100dvh;
  object-fit: cover;
  z-index: 1;
  background: #000;
}

/* IOS Corner Ticks Implementation */
#boundingBox {
  position: absolute;
  width: 260px;
  height: 260px;
  z-index: 20;
  pointer-events: none;
  box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.6); /* Vignette */
}
#boundingBox::before,
#boundingBox::after,
#boundingBox span::before,
#boundingBox span::after {
  content: "";
  position: absolute;
  width: 24px;
  height: 24px;
  border: 4px solid #fff;
  border-radius: 2px;
}
/* Top Left */
#boundingBox::before {
  top: 0;
  left: 0;
  border-right: none;
  border-bottom: none;
}
/* Top Right */
#boundingBox::after {
  top: 0;
  right: 0;
  border-left: none;
  border-bottom: none;
}
/* Bottom Left */
.bb-bl {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 24px;
  height: 24px;
  border-left: 4px solid #fff;
  border-bottom: 4px solid #fff;
  border-radius: 2px;
}
/* Bottom Right */
.bb-br {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 24px;
  height: 24px;
  border-right: 4px solid #fff;
  border-bottom: 4px solid #fff;
  border-radius: 2px;
}
#boundingBox .bb-label {
  position: absolute;
  top: -40px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.8rem;
  font-weight: 700;
  color: #fff;
  opacity: 0.8;
}
/* Corner pieces */
.bb-c {
  display: none;
}

.scan-actions-bar {
  position: fixed;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  width: 90%;
  z-index: 999;
}

.btn-scan-main {
  width: 100%;
}

.btn-scan-main {
  width: 100%;
  max-width: 300px;
  height: 56px;
  border-radius: 28px;
  font-size: 1rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  background: var(--accent);
  color: #000;
  border: none;
  box-shadow: 0 15px 40px rgba(79, 209, 197, 0.45);
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}
.btn-scan-main:active {
  transform: scale(0.95);
  box-shadow: 0 5px 15px rgba(79, 209, 197, 0.2);
}
.btn-scan-main svg {
  width: 22px;
  height: 22px;
  opacity: 1;
}

/* Refined Progress for Fullscreen */
#progressRing {
  position: fixed;
  bottom: calc(40px + env(safe-area-inset-bottom));
  right: 1.5rem;
  width: 72px;
  height: 72px;
  background: rgba(10, 15, 30, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 50%;
  z-index: 500;
  display: none;
  align-items: center;
  justify-content: center;
  border: 1.5px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.6);
}
.pr-bg {
  stroke: rgba(255, 255, 255, 0.08);
}
.pr-fill {
  stroke: var(--accent);
  filter: drop-shadow(0 0 6px var(--accent-glow));
}
.ring-inner span {
  font-size: 1.1rem;
  font-weight: 900;
  color: #fff;
}
.ring-inner small {
  color: var(--accent);
}

.cam-warning {
  position: fixed;
  top: 140px;
  left: 50%;
  transform: translateX(-50%);
  background: #ef4444;
  color: #fff;
  padding: 0.6rem 1.25rem;
  border-radius: 10px;
  font-size: 0.85rem;
  font-weight: 800;
  z-index: 10;
  display: none;
  white-space: nowrap;
  width: auto;
  pointer-events: none;
  box-shadow: 0 10px 30px rgba(239, 68, 68, 0.4);
}
@keyframes warnSlideDown {
  from {
    transform: translate(-50%, -20px);
    opacity: 0;
  }
  to {
    transform: translate(-50%, 0);
    opacity: 1;
  }
}

/* Complete Overlay Fullscreen */
#completePanel {
  position: fixed;
  inset: 0;
  background: rgba(10, 15, 25, 0.95);
  backdrop-filter: blur(30px);
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  text-align: center;
}
.complete-inner {
  max-width: 400px;
}
.success-icon {
  color: var(--accent);
  margin-bottom: 1.5rem;
}
.complete-actions {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-top: 2rem;
  width: 100%;
}
.complete-actions .btn {
  width: 100%;
  height: 50px;
  border-radius: 25px;
}

/* ── FRAME BAR Refined for Scanner ── */
.frame-bar {
  position: absolute;
  bottom: 2rem;
  left: 2rem;
  display: none; /* Can be enabled if needed */
}

/* ══════════════════════════════════════════════════════
   ADMIN PANEL
   ══════════════════════════════════════════════════════ */
.admin-layout {
  display: flex;
  min-height: calc(100vh - 62px);
  margin-top: 62px;
}

.admin-sidebar {
  width: 240px;
  flex-shrink: 0;
  border-right: 1px solid var(--border);
  padding: 1.5rem 0;
  background: var(--bg-2);
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.admin-nav {
  padding: 0 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.anav-item {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.65rem 0.9rem;
  border-radius: var(--radius);
  color: var(--text-soft);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--t);
  user-select: none;
  border: none;
  background: none;
  font-family: var(--font);
  width: 100%;
  text-align: left;
}
.anav-item:hover {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
}
.anav-item.active {
  background: var(--accent-dim);
  color: var(--accent);
}
.anav-item svg {
  flex-shrink: 0;
}

.admin-kpis {
  padding: 0 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  border-top: 1px solid var(--border);
  padding-top: 1.5rem;
}
.kpi-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.kpi-lbl {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.kpi-val {
  font-size: 1.15rem;
  font-weight: 800;
}

.admin-main {
  flex: 1;
  padding: 2rem;
  overflow-y: auto;
  background: var(--bg);
}

.admin-tab {
  display: none;
}
.admin-tab.active {
  display: block;
}

.admin-tab-title {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

/* TABLE */
.tbl-wrap {
  overflow-x: auto;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--glass-bg);
  padding: 1px; /* Add subtle padding to prevent box-shadow clipping on scroll */
}
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}
thead th {
  text-align: left;
  padding: 0.75rem 1rem;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border);
  font-weight: 600;
  white-space: nowrap;
  background: rgba(255, 255, 255, 0.015);
}
tbody td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}
tbody tr:last-child td {
  border-bottom: none;
}
tbody tr:hover td {
  background: rgba(255, 255, 255, 0.02);
}

.tbl-id {
  font-size: 0.72rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 0.12rem 0.45rem;
  color: var(--text-muted);
  font-family: monospace;
}

.select-inline {
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  padding: 0.3rem 0.6rem;
  font-size: 0.8rem;
  font-family: var(--font);
  cursor: pointer;
  outline: none;
  transition: border-color var(--t);
}
.select-inline:focus {
  border-color: rgba(79, 209, 197, 0.4);
}

.btn-del {
  background: rgba(248, 113, 113, 0.08);
  border: 1px solid rgba(248, 113, 113, 0.18);
  border-radius: var(--radius-sm);
  color: #f87171;
  padding: 0.3rem 0.7rem;
  font-size: 0.78rem;
  cursor: pointer;
  transition: all var(--t);
  font-family: var(--font);
}
.btn-del:hover {
  background: rgba(248, 113, 113, 0.16);
}

.tbl-path {
  font-family: monospace;
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* ══════════════════════════════════════════════════════
   RESPONSIVE — MOBİL (Android / iOS)
   ══════════════════════════════════════════════════════ */
@media (max-width: 900px) {
  /* Dashboard: Sidebar üstte, kamera alta geliyor ama
       telefon için kamera tam ekran overlay yapıyoruz */
  .dash-layout {
    flex-direction: column;
    height: auto;
    overflow: visible;
  }
  .dash-sidebar {
    width: 100%;
    border-right: none;
    border-bottom: 1px solid var(--border);
    flex-direction: row;
    flex-wrap: wrap;
    max-height: none;
  }
  .sidebar-top,
  .sidebar-stats,
  .sidebar-section {
    padding: 0.75rem 1rem;
  }

  .cam-main {
    height: calc(100vh - 62px - 200px);
    min-height: 300px;
    position: relative;
  }
  .cam-controls-bar {
    padding: 0.6rem 0.8rem;
  }
  .cam-controls-bar h2 {
    font-size: 0.9rem;
  }

  .admin-layout {
    flex-direction: column;
  }
  .admin-sidebar {
    width: 100%;
    border-right: none;
    border-bottom: 1px solid var(--border);
    padding: 1rem;
  }
  .admin-nav {
    flex-direction: row;
    flex-wrap: nowrap;
    overflow-x: auto;
    gap: 0.5rem;
    padding-bottom: 0.5rem;
  }
  .anav-item {
    flex: 1;
    min-width: 130px;
    justify-content: center;
  }
}

@media (max-width: 600px) {
  .navbar {
    padding: 0 0.75rem;
  }
  .hero {
    padding: 3rem 0.75rem;
    overflow-x: hidden;
  } /* prevent horizontal bleed */
  .hero-title {
    font-size: clamp(1.8rem, 10vw, 3rem);
    letter-spacing: -0.03em;
  }
  .hero-inner {
    max-width: 100%;
    padding: 0;
  }

  /* Hero stats: all 3 side-by-side on mobile */
  .hero-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
    margin-top: 2rem;
  }
  .hero-stats > div {
    padding: 0 0.5rem;
    margin-bottom: 0;
  }
  .hero-stats > div:not(:last-child)::after {
    display: none;
  }
  .hero-stat-num {
    font-size: 1.5rem;
  }
  .hero-stat-lbl {
    font-size: 0.6rem;
  }

  /* Navbar: shorten account button text on small screens */
  .btn-account {
    font-size: 0.75rem;
    padding: 0.4rem 0.6rem;
    max-width: 160px;
  }
  .btn-account span + span, /* email text */
    .btn-account > span:last-child {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  /* Dropdown stays right-aligned, max-width prevents overflow */
  .dropdown-menu {
    right: 0;
    left: auto;
    max-width: calc(100vw - 1.5rem);
  }

  .container {
    padding: 0 1rem;
  }
  .section {
    padding: 4rem 0;
  }
  .auth-card {
    padding: 1.8rem 1.2rem;
    margin: 1rem;
  }
  .admin-main {
    padding: 1rem;
  }
  .quote-block {
    padding: 1.5rem;
  }
  .pricing-grid {
    display: flex;
    flex-direction: column;
    align-items: stretch; /* Mobilde kartlar tam genişlik olsun */
    gap: 1.5rem;
    margin-top: 2rem;
  }
  .price-card {
    flex: 1 1 auto;
    width: 100%;
    max-width: 100%;
    min-height: auto; /* Mobilde yükseklik otomatik olsun, içerik sığsın */
    padding: 2rem 1.25rem;
    transform: none !important;
    border-color: rgba(255, 255, 255, 0.12); /* Daha belirgin kenar */
  }
  .price-value {
    font-size: 2.8rem;
  }
  .price-desc {
    font-size: 0.85rem;
    margin-bottom: 1.5rem;
  }
  .price-features {
    margin-bottom: 2rem;
  }
  .price-features li {
    font-size: 0.85rem;
  }
  .price-card.featured {
    transform: none;
    border-color: rgba(79, 209, 197, 0.4);
  }
  .price-badge {
    top: 15px;
    right: -25px;
    font-size: 0.55rem;
    padding: 4px 30px;
  }
  .steps-grid {
    grid-template-columns: 1fr;
  }

  /* ─── DASHBOARD MOBILE: sidebar top bar + camera fills rest ─── */
  .dash-layout {
    flex-direction: column !important;
    height: 100dvh;
    overflow: hidden;
  }
  /* Sidebar collapses to a single horizontal strip */
  .dash-sidebar {
    width: 100% !important;
    height: auto !important;
    max-height: none !important;
    flex-shrink: 0;
    flex-direction: row !important;
    align-items: center;
    border-right: none;
    border-bottom: 1px solid var(--border);
    overflow: visible;
    background: var(--bg-2);
    padding: 0.4rem 0.6rem;
    gap: 0.5rem;
  }
  /* Show ONLY sidebar-top (user info) inline, hide everything else */
  .sidebar-top {
    display: flex !important;
    flex-direction: row;
    align-items: center;
    gap: 0.6rem;
    padding: 0 1rem;
    border-bottom: none;
    flex: 1;
    min-width: 0;
    height: 100%;
  }
  .user-row {
    gap: 0.6rem;
  }
  .user-ava {
    width: 34px;
    height: 34px;
    font-size: 0.9rem;
  }
  .user-name {
    font-size: 0.8rem;
    font-weight: 700;
  }
  .user-email {
    display: none;
  }
  .plan-pill {
    font-size: 0.6rem;
    padding: 2px 6px;
  }
  /* Show sidebar gallery as a vertical overlay on the left */
  .sidebar-gallery {
    display: flex !important;
    position: absolute;
    left: 12px;
    top: 80px;
    bottom: 120px;
    width: 45px !important;
    flex-direction: column;
    z-index: 1500;
    background: none;
    padding: 0;
    border: none;
    pointer-events: none; /* Let clicks pass through to camera if needed, but thumbnails will have pointer-events: auto */
  }
  .sidebar-gallery .sidebar-title {
    display: none;
  }
  .gallery-thumbs {
    display: flex;
    flex-direction: column;
    gap: 8px;
    overflow-y: auto;
    padding: 4px;
    pointer-events: auto;
    max-height: 100%;
    scrollbar-width: none;
  }
  .gallery-thumbs::-webkit-scrollbar {
    display: none;
  }

  .gallery-thumb {
    width: 38px;
    height: 38px;
    flex-shrink: 0;
    border-radius: 6px;
    border: 2px solid rgba(255, 255, 255, 0.2);
    overflow: hidden;
    position: relative;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
  }
  .gallery-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }
  .gallery-thumb-num {
    position: absolute;
    bottom: 1px;
    right: 2px;
    font-size: 0.5rem;
    background: var(--accent);
    color: #000;
    padding: 0 2px;
    border-radius: 2px;
    font-weight: 800;
  }
  .sidebar-section {
    display: none !important;
  }
  .sidebar-stats {
    display: flex !important;
    flex-direction: row;
    gap: 0.5rem;
    padding: 0;
    border-bottom: none;
    border-left: 1px solid var(--border);
    padding-left: 0.6rem;
    flex-shrink: 0;
  }
  .ss-item {
    text-align: center;
  }
  .ss-val {
    font-size: 0.95rem;
  }
  .ss-lbl {
    font-size: 0.5rem;
  }

  /* Dashboard Main: Clean Flex Vertical */
  .dash-main {
    flex: 1 !important;
    overflow-y: auto !important;
    padding: 1.5rem 1.25rem !important;
    background: var(--bg);
    display: flex !important;
    flex-direction: column !important;
    gap: 20px !important;
  }
  .dash-top {
    display: none !important;
  }

  .camera-box {
    flex: 1;
    display: flex;
    flex-direction: column;
    border-radius: 0;
    min-height: 0;
  }

  /* Fixed positioning for mobile controls during fullscreen/streaming */
  .cam-controls-bar {
    position: absolute !important;
    top: auto !important;
    bottom: 30px !important;
    left: 15px !important;
    right: 15px !important;
    flex-shrink: 0;
    padding: 1rem 0.8rem;
    gap: 12px !important;
    justify-content: center !important;
    background: rgba(15, 20, 30, 0.9) !important;
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    z-index: 1000;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.7);
    transition:
      transform 0.3s ease,
      opacity 0.3s ease;
  }
  .cam-controls-bar.hidden {
    transform: translateY(120px);
    opacity: 0;
    pointer-events: none;
  }
  .cam-controls-bar .btn {
    flex: 1;
    min-width: 0;
    padding: 0.6rem 0.4rem;
    font-size: 0.72rem;
    min-height: 54px;
    white-space: nowrap;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #fff;
  }
  .cam-controls-bar .btn-primary {
    background: var(--accent);
    color: #000;
    border: none;
  }
  .cam-controls-bar .btn svg {
    width: 18px;
    height: 18px;
  }

  .cam-placeholder {
    flex: 1;
  }

  /* Make sure video sits behind controls when streaming */
  #cameraFeed {
    position: fixed;
    inset: 0;
    z-index: 1;
    width: 100vw !important;
    height: 100dvh !important;
    object-fit: cover !important;
    display: block !important;
  }

  /* Frame bar smaller */
  .frame-bar {
    grid-template-columns: repeat(10, 1fr);
    gap: 3px;
  }
  .frame-slot {
    height: 18px;
  }

  /* Admin tables compact */
  thead th,
  tbody td {
    padding: 0.55rem 0.6rem;
    font-size: 0.75rem;
  }
}

/* Çok küçük ekranlar (örn. dar Android) */
@media (max-width: 380px) {
  .hero-title {
    font-size: 2rem;
  }
  .dash-sidebar {
    max-height: 150px;
  }
  .frame-bar {
    grid-template-columns: repeat(10, 1fr);
  }
}

/* ══════════════════════════════════════════════════════
   SIDEBAR GALLERY (Sol taraf — Çekilen Fotoğraflar)
   ══════════════════════════════════════════════════════ */
.sidebar-gallery {
  padding: 1.2rem 1.5rem;
  border-bottom: 1px solid var(--border);
}

.gallery-thumbs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  max-height: 200px;
  overflow-y: auto;
}

.gallery-thumb {
  position: relative;
  aspect-ratio: 1;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.03);
}
.gallery-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.gallery-thumb-num {
  position: absolute;
  bottom: 3px;
  right: 4px;
  font-size: 0.58rem;
  font-weight: 700;
  background: rgba(0, 0, 0, 0.7);
  color: var(--accent);
  padding: 1px 5px;
  border-radius: 4px;
}

/* ══════════════════════════════════════════════════════
   ADMIN — RANK BADGE & COLOR SWATCH
   ══════════════════════════════════════════════════════ */
.rank-badge {
  display: inline-block;
  padding: 0.18rem 0.6rem;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.rank-user {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-muted);
}
.rank-admin {
  background: rgba(167, 139, 250, 0.1);
  color: #c4b5fd;
}

.color-swatch {
  display: inline-block;
  width: 14px;
  height: 14px;
  border-radius: 4px;
  vertical-align: middle;
  margin-right: 0.4rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

/* Plan pill — Enterprise alias */
.plan-enterprise {
  background: rgba(251, 191, 36, 0.12);
  color: #fbbf24;
}

/* ══════════════════════════════════════════════════════
   PROFILE AVATAR (Büyük)
   ══════════════════════════════════════════════════════ */
.profile-ava {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 900;
  color: #fff;
  margin: 0 auto 0.8rem;
  border: 2px solid rgba(255, 255, 255, 0.12);
}

/* ══════════════════════════════════════════════════════
   FULLSCREEN MODE — Native & Pseudo Fallback
   ══════════════════════════════════════════════════════ */
.camera-box:fullscreen,
.camera-box:-webkit-full-screen,
.camera-box:-moz-full-screen,
.camera-box:-ms-fullscreen,
.camera-box.pseudo-fullscreen {
  position: fixed !important;
  inset: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
  z-index: 9999 !important;
  background: #000 !important;
  border-radius: 0 !important;
  display: flex !important;
  align-items: center;
  justify-content: center;
}

.camera-box.is-fullscreen #cameraFeed,
.camera-box:fullscreen #cameraFeed,
.camera-box:-webkit-full-screen #cameraFeed {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
}

/* Pseudo-fullscreen active adjustments */
.camera-box.pseudo-fullscreen #cameraFeed {
  display: block; /* Ensure video is visible in fallback */
}

/* ══════════════════════════════════════════════════════
   RESPONSIVE — GALERİ MOBİL
   ══════════════════════════════════════════════════════ */
@media (max-width: 900px) {
  .sidebar-gallery {
    padding: 0.75rem 1rem;
  }
  .gallery-thumbs {
    grid-template-columns: repeat(6, 1fr);
    max-height: 80px;
  }
}

@media (max-width: 600px) {
  .gallery-thumbs {
    grid-template-columns: repeat(4, 1fr);
    max-height: 60px;
  }
}

/* ══════════════════════════════════════════════════════
   ADMIN — FOTOĞRAF GALERİSİ & MODAL
   ══════════════════════════════════════════════════════ */
.admin-photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 10px;
}
.admin-photo-card {
  position: relative;
  aspect-ratio: 4/3;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.03);
  cursor: pointer;
  transition:
    border-color var(--t),
    transform var(--t);
}
.admin-photo-card:hover {
  border-color: rgba(79, 209, 197, 0.3);
  transform: translateY(-2px);
}
.admin-photo-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.admin-photo-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 6px 8px;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
}
.admin-photo-idx {
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--accent);
  background: rgba(0, 0, 0, 0.5);
  padding: 1px 6px;
  border-radius: 4px;
}
.admin-photo-user {
  font-size: 0.6rem;
  color: var(--text-muted);
  text-overflow: ellipsis;
  overflow: hidden;
  white-space: nowrap;
  max-width: 100px;
}

/* Photo Modal */
.photo-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 20000;
  align-items: center;
  justify-content: center;
}
.photo-modal.active {
  display: flex;
}
.photo-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(8px);
}
.photo-modal-content {
  position: relative;
  max-width: 90vw;
  max-height: 85vh;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}
.photo-modal-content img {
  max-width: 100%;
  max-height: 70vh;
  object-fit: contain;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
}
.photo-modal-close {
  position: absolute;
  top: -40px;
  right: 0;
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  transition: color var(--t);
  padding: 4px;
}
.photo-modal-close:hover {
  color: var(--text);
}
.photo-modal-info {
  display: flex;
  gap: 1.5rem;
  font-size: 0.8rem;
  color: var(--text-soft);
}
.photo-modal-info strong {
  color: var(--text-muted);
  margin-right: 0.3rem;
}

/* Gallery Empty */
.gallery-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.8rem;
  color: var(--text-muted);
  font-size: 0.85rem;
  padding: 3rem 2rem;
  text-align: center;
}

/* Admin Loading */
.admin-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 62px);
}

/* ══════════════════════════════════════════════════════
   IMPROVED MOBILE FULLSCREEN
   ══════════════════════════════════════════════════════ */
.camera-box.pseudo-fullscreen {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
  z-index: 99999 !important;
  background: #000 !important;
  border-radius: 0 !important;
}
.camera-box.pseudo-fullscreen #cameraFeed {
  display: block !important;
  width: 100% !important;
  height: 100dvh !important;
  object-fit: cover !important;
}
.camera-box.pseudo-fullscreen .cam-controls-bar {
  z-index: 100000 !important;
}
.camera-box.pseudo-fullscreen #boundingBox {
  z-index: 100000 !important;
}
.camera-box.pseudo-fullscreen #progressRing {
  z-index: 100000 !important;
}
.camera-box.pseudo-fullscreen #scanStatus {
  z-index: 100000 !important;
}
.camera-box.pseudo-fullscreen #completePanel {
  z-index: 100000 !important;
}

@media (max-width: 600px) {
  .admin-photo-grid {
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    gap: 6px;
  }
  .photo-modal-info {
    flex-direction: column;
    gap: 0.3rem;
  }
}

@media (max-width: 768px) {
  .hero {
    padding-top: calc(62px + 3rem);
    align-items: flex-start;
  }
}

/* End of File Cleanup */

/* ══════════════════════════════════════════════════════
   MOBILE PROJECTS VIEW — Full CSS
   Visible only on mobile (max-width: 767px)
   Desktop: projects-mobile-shell is hidden (display:none)
   ══════════════════════════════════════════════════════ */

/* Desktop: hide the mobile shell */
.projects-mobile-shell {
  display: none;
}

/* Mobile: show our shell, hide the desktop navbar + dash-layout */
@media (max-width: 767px) {

  /* Show mobile Projects */
  .projects-mobile-shell {
    display: flex;
    flex-direction: column;
    position: fixed;
    inset: 0;
    background: #000;
    z-index: 9000;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  /* Hide desktop elements when mobile shell is shown */
  .navbar,
  .dash-layout {
    display: none !important;
  }

  /* ── HEADER ─────────────────────────────────────── */
  .pm-header {
    position: sticky;
    top: 0;
    left: 0;
    right: 0;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    background: #000;
    z-index: 10;
    flex-shrink: 0;
  }

  .pm-title {
    font-size: 1.4rem;
    font-weight: 900;
    color: #fff;
    letter-spacing: -0.02em;
  }

  .pm-icons {
    display: flex;
    align-items: center;
    gap: 16px;
    color: rgba(255, 255, 255, 0.65);
  }

  .pm-icons svg {
    cursor: pointer;
    transition: color 0.2s;
    flex-shrink: 0;
  }

  .pm-icons svg:hover { color: #fff; }

  /* ── CARD LIST ──────────────────────────────────── */
  .pm-list {
    flex: 1;
    padding: 12px 16px 120px;
    display: flex;
    flex-direction: column;
    gap: 12px;
  }

  /* ── PROJECT CARD ───────────────────────────────── */
  .pm-card {
    border-radius: 20px;
    overflow: hidden;
    background: rgba(30, 30, 30, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.07);
    position: relative;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    -webkit-tap-highlight-color: transparent;
    cursor: pointer;
  }

  .pm-card:active {
    transform: scale(0.98);
  }

  /* ── CARD THUMBNAIL ─────────────────────────────── */
  .pm-card-thumb {
    width: 100%;
    height: 140px;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
  }

  .pm-card-thumb img,
  .pm-card-thumb model-viewer {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
  }

  .pm-card:hover .pm-card-thumb img,
  .pm-card:hover .pm-card-thumb model-viewer {
    transform: scale(1.03);
  }

  /* Önizleme kartları içindeki model-viewer min-height ayarı */
  .pm-card-thumb model-viewer,
  .community-item-card model-viewer {
    min-height: auto !important;
  }

  .pm-thumb-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(59, 158, 255, 0.08) 0%, rgba(30, 30, 30, 0.9) 100%);
  }

  /* ── BADGES ─────────────────────────────────────── */
  .pm-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 5px 12px;
    border-radius: 50px;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.02em;
    text-transform: capitalize;
    z-index: 3;
  }

  .badge-unprocessed {
    background: #f59e0b;
    color: #000;
  }

  .badge-completed {
    background: #22c55e;
    color: #fff;
  }

  .badge-processing {
    background: #3b9eff;
    color: #fff;
  }

  .badge-ready {
    background: #a855f7;
    color: #fff;
  }

  .badge-failed {
    background: #ef4444;
    color: #fff;
  }

  /* ── THREE DOT MENU BUTTON ──────────────────────── */
  .pm-card-menu {
    position: absolute;
    bottom: 12px;
    right: 12px;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.5);
    border: none;
    color: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 3;
    transition: background 0.2s;
    -webkit-tap-highlight-color: transparent;
  }

  .pm-card-menu:hover {
    background: rgba(0, 0, 0, 0.75);
    color: #fff;
  }

  /* ── CARD INFO ──────────────────────────────────── */
  .pm-card-info {
    padding: 14px 16px 16px;
  }

  .pm-card-date {
    font-size: 1rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 4px;
    letter-spacing: -0.01em;
  }

  .pm-card-meta {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.45);
    font-weight: 500;
  }

  /* ── EMPTY STATE ────────────────────────────────── */
  .pm-empty {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 40px 24px;
    min-height: 60vh;
  }

  .pm-empty-icon {
    margin-bottom: 24px;
    opacity: 0.7;
  }

  .pm-empty-title {
    font-size: 1.3rem;
    font-weight: 800;
    color: #fff;
    margin-bottom: 12px;
    letter-spacing: -0.02em;
  }

  .pm-empty-sub {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.45);
    line-height: 1.55;
    max-width: 280px;
    margin: 0 auto 28px;
  }

  .pm-quickstart-btn {
    display: inline-block;
    padding: 14px 28px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 14px;
    color: #fff;
    font-size: 0.95rem;
    font-weight: 700;
    text-decoration: none;
    transition: background 0.2s;
    -webkit-tap-highlight-color: transparent;
  }

  .pm-quickstart-btn:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
  }

  /* ── FAB BUTTON ─────────────────────────────────── */
  .pm-fab {
    position: fixed;
    bottom: 36px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 60px;
    background: #3b9eff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-decoration: none;
    z-index: 9100;
    box-shadow: 0 6px 28px rgba(59, 158, 255, 0.5);
    transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.2s;
    -webkit-tap-highlight-color: transparent;
  }

  .pm-fab:hover {
    transform: translateX(-50%) scale(1.08);
    box-shadow: 0 10px 36px rgba(59, 158, 255, 0.65);
    color: #fff;
  }

  .pm-fab:active {
    transform: translateX(-50%) scale(0.94);
  }

  .pm-community-fab {
    position: fixed;
    bottom: 36px;
    left: 24px;
    right: auto;
    width: 60px;
    height: 60px;
    background: rgba(30, 30, 30, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    z-index: 9100;
    backdrop-filter: blur(8px);
    transition: transform 0.2s, background 0.2s;
    transform: none; /* override the translateX */
  }

  .pm-community-fab:active {
    transform: scale(0.94);
  }

  .pm-upload-fab {
    position: fixed;
    bottom: 36px;
    right: 24px;
    left: auto;
    width: 60px;
    height: 60px;
    background: rgba(30, 30, 30, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    z-index: 9100;
    backdrop-filter: blur(8px);
    transition: transform 0.2s, background 0.2s;
    transform: none; /* override the translateX */
  }

  .pm-upload-fab:active {
    transform: scale(0.94);
  }

  /* ── CONTEXT MENU ───────────────────────────────── */
  .pm-context-menu {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #1c1c1e;
    border-radius: 24px 24px 0 0;
    padding: 12px 0 36px;
    z-index: 9500;
    transform: translateY(100%);
    transition: transform 0.32s cubic-bezier(0.175, 0.885, 0.32, 1.05);
    box-shadow: 0 -8px 40px rgba(0, 0, 0, 0.6);
  }

  .pm-context-menu.open {
    transform: translateY(0);
  }

  /* Drag handle */
  .pm-context-menu::before {
    content: '';
    display: block;
    width: 40px;
    height: 4px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 2px;
    margin: 0 auto 12px;
  }

  .pm-ctx-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 24px;
    color: #fff;
    font-size: 0.97rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s;
    -webkit-tap-highlight-color: transparent;
  }

  .pm-ctx-item:active {
    background: rgba(255, 255, 255, 0.07);
  }

  .pm-ctx-item svg {
    opacity: 0.75;
    flex-shrink: 0;
  }

  .pm-ctx-item.danger {
    color: #ff4757;
  }

  .pm-ctx-item.danger svg {
    opacity: 1;
  }

  .pm-ctx-divider {
    height: 1px;
    background: rgba(255, 255, 255, 0.08);
    margin: 4px 0;
  }

  /* Context menu backdrop */
  .pm-ctx-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9400;
    backdrop-filter: blur(2px);
  }

  .pm-ctx-backdrop.open {
    display: block;
  }

} /* end @media (max-width: 767px) */
/* Eslint-disable-like overrides for Desktop visibility fallbacks */
@media (min-width: 601px) {
  #pmRenameModal {
    display: none !important;
  }
  
  /* Desktop Context Menu styling */
  .pm-context-menu {
    top: 50% !important;
    left: 50% !important;
    right: auto !important;
    bottom: auto !important;
    width: 320px !important;
    transform: translate(-50%, -50%) scale(0.9) !important;
    border-radius: 20px !important;
    padding: 20px !important;
    opacity: 0;
    pointer-events: none;
    display: block !important;
  }
  
  .pm-context-menu.open {
    transform: translate(-50%, -50%) scale(1) !important;
    opacity: 1;
    pointer-events: auto;
  }
  
  .pm-context-menu::before {
    display: none;
  }
  
  .pm-ctx-item:hover {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
  }
}
