/* ─── Picksy Agency — minimal, dark, modern ─── */

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

:root {
  --bg: #0a0a0f;
  --bg-2: #0e0e16;
  --surface: #11111a;
  --surface-2: #161620;
  --surface-3: #1c1c28;
  --border: rgba(255, 255, 255, 0.07);
  --border-strong: rgba(255, 255, 255, 0.14);
  --text: #f5f5fa;
  --text-dim: rgba(245, 245, 250, 0.7);
  --text-muted: rgba(245, 245, 250, 0.45);
  --accent: #7c5cff;
  --accent-2: #a78bfa;
  --accent-glow: rgba(124, 92, 255, 0.35);
  --success: #4ade80;
  --danger: #f87171;
  --warning: #fbbf24;
  --radius: 16px;
  --radius-sm: 10px;
  --radius-lg: 22px;
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: "JetBrains Mono", "SFMono-Regular", Menlo, monospace;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --shadow-sm: 0 2px 6px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 12px 36px rgba(0, 0, 0, 0.45);
  --max-w: 1240px;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

body.no-scroll { overflow: hidden; }

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s var(--ease);
}

a:hover { color: var(--accent-2); }

h1, h2, h3, h4 {
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

input, textarea, select {
  font-family: inherit;
  color: var(--text);
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  font-size: 0.95rem;
  width: 100%;
  outline: none;
  transition: border-color 0.2s var(--ease), background 0.2s var(--ease);
}

input:focus, textarea:focus, select:focus {
  border-color: var(--accent);
  background: var(--surface-3);
}

textarea { resize: vertical; min-height: 80px; }

::selection { background: var(--accent-glow); color: var(--text); }

.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
  width: 100%;
}

/* ─── Buttons ─── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--text);
  border: 1px solid var(--border);
  transition: all 0.2s var(--ease);
  white-space: nowrap;
  text-decoration: none;
}

.btn:hover {
  border-color: var(--border-strong);
  background: var(--surface-3);
  color: var(--text);
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--text);
  color: var(--bg);
  border-color: var(--text);
}

.btn-primary:hover {
  background: var(--accent);
  color: var(--text);
  border-color: var(--accent);
  box-shadow: 0 10px 32px var(--accent-glow);
}

.btn-ghost {
  background: transparent;
  border-color: var(--border-strong);
}

.btn-sm { padding: 8px 14px; font-size: 0.85rem; }
.btn-lg { padding: 16px 28px; font-size: 1rem; }
.btn-block { width: 100%; }

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
}

.btn-danger { color: var(--danger); border-color: rgba(248, 113, 113, 0.3); }
.btn-danger:hover { background: rgba(248, 113, 113, 0.12); }

/* ─── Header ─── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10, 10, 15, 0.7);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  padding-top: 16px;
  padding-bottom: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
  color: var(--text);
}

.brand:hover { color: var(--text); }

.brand-mark {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--accent) 0%, #ec4899 100%);
  box-shadow: 0 4px 18px var(--accent-glow);
  position: relative;
  flex-shrink: 0;
}

.brand-mark::after {
  content: "";
  position: absolute;
  inset: 6px;
  background: var(--bg);
  border-radius: 4px;
}

.main-nav {
  display: flex;
  gap: 28px;
  margin-left: auto;
  margin-right: 24px;
}

.nav-link {
  position: relative;
  font-size: 0.92rem;
  color: var(--text-dim);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 0;
}

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

.nav-link-ai {
  color: var(--text);
}

.ai-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 12px var(--accent), 0 0 4px var(--accent);
  animation: pulse 2s infinite;
  flex-shrink: 0;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(0.8); }
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.user-chip {
  padding: 6px 12px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 0.85rem;
  color: var(--text-dim);
  max-width: 180px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.menu-toggle {
  display: none;
  width: 40px;
  height: 40px;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 4px;
}

.menu-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.25s var(--ease), opacity 0.25s var(--ease);
}

.mobile-menu {
  display: none;
  flex-direction: column;
  gap: 12px;
  padding: 16px 24px 24px;
  border-top: 1px solid var(--border);
  background: var(--bg);
}

.mobile-link {
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
  color: var(--text-dim);
  font-size: 1rem;
}

@media (max-width: 880px) {
  .main-nav, .header-actions { display: none; }
  .menu-toggle { display: flex; }
  .mobile-menu.is-open { display: flex; }
}

/* ─── Hero ─── */
.hero {
  position: relative;
  padding: 96px 0 64px;
  overflow: hidden;
}

.hero-glow {
  position: absolute;
  width: 800px;
  height: 800px;
  border-radius: 50%;
  background: radial-gradient(closest-side, var(--accent-glow), transparent 70%);
  top: -300px;
  left: 50%;
  transform: translateX(-50%);
  filter: blur(60px);
  z-index: 0;
  pointer-events: none;
}

.hero-inner {
  position: relative;
  z-index: 1;
  text-align: center;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: var(--surface-2);
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  font-size: 0.85rem;
  color: var(--text-dim);
  margin-bottom: 28px;
}

.hero-badge-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 12px var(--accent);
}

.hero-title {
  font-size: clamp(2.2rem, 6vw, 4.4rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1;
  max-width: 16ch;
  margin: 0 auto 24px;
  background: linear-gradient(180deg, var(--text) 30%, rgba(245, 245, 250, 0.4) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-sub {
  font-size: clamp(1rem, 1.4vw, 1.15rem);
  color: var(--text-dim);
  max-width: 56ch;
  margin: 0 auto 36px;
  line-height: 1.6;
}

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

.hero-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  max-width: 720px;
  margin: 0 auto;
}

.stat {
  background: var(--bg);
  padding: 22px 16px;
  text-align: center;
}

.stat-value {
  font-size: clamp(1.4rem, 2.5vw, 2rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--text);
}

.stat-label {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-top: 6px;
}

@media (max-width: 600px) {
  .hero-stats { grid-template-columns: repeat(2, 1fr); }
}

/* ─── Sections ─── */
.section {
  padding: 96px 0;
  position: relative;
}

.section + .section { padding-top: 32px; }

.section-head {
  margin-bottom: 56px;
  max-width: 720px;
}

.section-eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--accent-2);
  font-weight: 600;
  margin-bottom: 12px;
}

.section-title {
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: 16px;
}

.section-sub {
  font-size: 1.05rem;
  color: var(--text-dim);
  max-width: 60ch;
}

.section-cta {
  text-align: center;
  margin-top: 48px;
}

/* ─── Category grid (cards) ─── */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.cat-card {
  position: relative;
  background: var(--bg);
  padding: 32px 28px 28px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 220px;
  transition: background 0.25s var(--ease);
  color: var(--text);
}

.cat-card:hover {
  background: var(--surface);
  color: var(--text);
}

.cat-num {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-muted);
  letter-spacing: 0.05em;
}

.cat-name {
  font-size: 1.25rem;
  margin-top: 8px;
  margin-bottom: 4px;
}

.cat-desc {
  color: var(--text-dim);
  font-size: 0.92rem;
  flex: 1;
}

.cat-arrow {
  align-self: flex-start;
  margin-top: 12px;
  font-size: 1.2rem;
  color: var(--text-muted);
  transition: transform 0.25s var(--ease), color 0.25s var(--ease);
}

.cat-card:hover .cat-arrow {
  color: var(--accent-2);
  transform: translateX(6px);
}

/* ─── Product cards ─── */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}

.product-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: border-color 0.25s var(--ease), transform 0.25s var(--ease);
  color: var(--text);
}

.product-card:hover {
  border-color: var(--border-strong);
  transform: translateY(-3px);
  color: var(--text);
}

.product-cover {
  width: 100%;
  aspect-ratio: 16 / 10;
  background-color: var(--surface-2);
  background-size: cover;
  background-position: center top;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}

.product-cover-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--surface-2), var(--surface-3));
}

.product-cover-empty span {
  font-size: 2rem;
  font-weight: 700;
  color: var(--text-muted);
  letter-spacing: -0.02em;
}

.product-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 4px;
}

.product-cat {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
}

.product-badge {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  background: var(--accent-glow);
  color: var(--accent-2);
  padding: 3px 8px;
  border-radius: 999px;
  font-weight: 600;
}

.product-title {
  font-size: 1.1rem;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.product-desc {
  font-size: 0.9rem;
  color: var(--text-dim);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px solid var(--border);
}

.product-price {
  font-weight: 700;
  font-size: 1.05rem;
}

.product-arrow {
  color: var(--text-muted);
  transition: transform 0.25s var(--ease), color 0.25s var(--ease);
}

.product-card:hover .product-arrow {
  color: var(--accent-2);
  transform: translateX(4px);
}

/* ─── AI promo ─── */
.section-ai { background: var(--bg-2); }

.ai-promo {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.ai-promo-text {
  font-size: 1.05rem;
  color: var(--text-dim);
  margin: 16px 0 24px;
}

.ai-promo-list {
  list-style: none;
  margin-bottom: 32px;
}

.ai-promo-list li {
  padding: 10px 0;
  border-top: 1px solid var(--border);
  color: var(--text-dim);
  font-size: 0.95rem;
  position: relative;
  padding-left: 22px;
}

.ai-promo-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 18px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 10px var(--accent-glow);
}

.ai-mock {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ai-mock-bubble {
  padding: 14px 16px;
  border-radius: 14px;
  font-size: 0.92rem;
  line-height: 1.5;
  max-width: 90%;
}

.ai-mock-user {
  background: var(--surface-3);
  align-self: flex-end;
}

.ai-mock-bot {
  background: rgba(124, 92, 255, 0.08);
  border: 1px solid var(--accent-glow);
  align-self: flex-start;
}

.ai-mock-line {
  margin-top: 4px;
  color: var(--text-dim);
  font-size: 0.88rem;
}

@media (max-width: 880px) {
  .ai-promo { grid-template-columns: 1fr; gap: 32px; }
}

/* ─── Why grid ─── */
.why-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.why-card {
  background: var(--bg);
  padding: 32px 28px;
}

.why-num {
  font-family: var(--font-mono);
  color: var(--accent-2);
  font-size: 0.85rem;
  letter-spacing: 0.1em;
  margin-bottom: 16px;
}

.why-card h3 {
  font-size: 1.2rem;
  margin-bottom: 8px;
}

.why-card p {
  color: var(--text-dim);
  font-size: 0.92rem;
  line-height: 1.6;
}

/* ─── CTA block ─── */
.cta-block {
  text-align: center;
  background: linear-gradient(180deg, var(--surface), var(--bg-2));
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 64px 32px;
  position: relative;
  overflow: hidden;
}

.cta-block h2 {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  margin-bottom: 12px;
}

.cta-block p {
  color: var(--text-dim);
  max-width: 56ch;
  margin: 0 auto 28px;
}

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

/* ─── Footer ─── */
.site-footer {
  border-top: 1px solid var(--border);
  margin-top: 80px;
  padding-top: 56px;
}

.footer-inner {
  display: grid;
  grid-template-columns: 2fr repeat(3, 1fr);
  gap: 40px;
  padding-bottom: 40px;
}

.footer-col h4 {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-col li a {
  color: var(--text-dim);
  font-size: 0.92rem;
}

.footer-tagline {
  margin-top: 16px;
  color: var(--text-muted);
  font-size: 0.9rem;
  max-width: 32ch;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 24px;
  border-top: 1px solid var(--border);
  font-size: 0.85rem;
  color: var(--text-muted);
}

.footer-domain { font-family: var(--font-mono); }

@media (max-width: 880px) {
  .footer-inner { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 520px) {
  .footer-inner { grid-template-columns: 1fr; }
}

/* ─── Page head ─── */
.page-head {
  padding: 80px 0 32px;
  border-bottom: 1px solid var(--border);
}

.page-title {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  margin: 8px 0 12px;
}

.page-sub {
  color: var(--text-dim);
  max-width: 60ch;
  margin-bottom: 28px;
}

.search-bar {
  display: flex;
  gap: 8px;
  margin-bottom: 24px;
  max-width: 640px;
}

.search-bar input {
  flex: 1;
}

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

.chip {
  padding: 8px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 0.88rem;
  color: var(--text-dim);
  transition: all 0.2s var(--ease);
  white-space: nowrap;
}

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

.chip-active {
  background: var(--text);
  color: var(--bg);
  border-color: var(--text);
}

.chip-active:hover { color: var(--bg); }

.chip-static {
  cursor: default;
  pointer-events: none;
}

.chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.empty-state {
  text-align: center;
  padding: 80px 24px;
  background: var(--surface);
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius);
}

.empty-state h3 { margin-bottom: 8px; }
.empty-state p {
  color: var(--text-dim);
  margin-bottom: 24px;
  max-width: 40ch;
  margin-left: auto;
  margin-right: auto;
}

/* ─── Product page ─── */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.breadcrumb a { color: var(--text-dim); }
.breadcrumb a:hover { color: var(--text); }

.product-layout {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 48px;
  align-items: start;
  margin-top: 24px;
}

@media (max-width: 880px) {
  .product-layout { grid-template-columns: 1fr; gap: 32px; }
}

.product-gallery {
  position: sticky;
  top: 100px;
}

.gallery-main {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 16 / 10;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gallery-main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.gallery-empty {
  font-size: 5rem;
  color: var(--text-muted);
  font-weight: 700;
}

.gallery-thumbs {
  display: flex;
  gap: 8px;
  margin-top: 12px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.thumb {
  flex: 0 0 80px;
  height: 60px;
  border-radius: 8px;
  overflow: hidden;
  border: 2px solid transparent;
  background: var(--surface);
  cursor: pointer;
  transition: border-color 0.2s var(--ease);
}

.thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.thumb-active { border-color: var(--accent); }

.product-aside { color: var(--text); }

.product-title-big {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  margin: 8px 0 12px;
  letter-spacing: -0.03em;
}

.product-short {
  color: var(--text-dim);
  margin-bottom: 28px;
  font-size: 1rem;
}

.price-box {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 20px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  margin-bottom: 24px;
}

.price-amount {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 800;
  letter-spacing: -0.04em;
}

.price-currency {
  color: var(--text-muted);
  font-size: 1.05rem;
  font-weight: 600;
}

.product-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 32px;
}

.spec-block {
  padding-top: 24px;
  border-top: 1px solid var(--border);
  margin-top: 24px;
}

.spec-block h4 {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.feature-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.feature-list li {
  padding-left: 18px;
  position: relative;
  font-size: 0.95rem;
  color: var(--text-dim);
}

.feature-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 9px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}

.desc-block h2 {
  font-size: 1.6rem;
  margin-bottom: 16px;
}

.rich-text {
  color: var(--text-dim);
  font-size: 1rem;
  line-height: 1.75;
  max-width: 70ch;
}

/* ─── Modal ─── */
.modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.modal[hidden] { display: none; }

.modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(5, 5, 10, 0.75);
  backdrop-filter: blur(8px);
}

.modal-body {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  padding: 32px;
  max-width: 480px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-md);
}

.modal-wide { max-width: 720px; }

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 36px;
  height: 36px;
  font-size: 1.5rem;
  color: var(--text-muted);
  border-radius: 50%;
  background: var(--surface-2);
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-close:hover { background: var(--surface-3); color: var(--text); }

.modal-body h3 { margin-bottom: 16px; font-size: 1.25rem; }

.modal-foot {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 8px;
  flex-wrap: wrap;
}

/* ─── Forms ─── */
.form-stack {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form-stack label {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-stack label > span {
  font-size: 0.85rem;
  color: var(--text-dim);
  font-weight: 500;
}

.form-stack label.check {
  flex-direction: row;
  align-items: center;
  gap: 10px;
}

.form-stack label.check input { width: auto; }

.form-status { font-size: 0.88rem; margin-top: 4px; color: var(--text-muted); }
.form-status-ok { color: var(--success); }
.form-status-err { color: var(--danger); }

.muted { color: var(--text-muted); font-size: 0.88rem; }

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

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

@media (max-width: 540px) {
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
}

.upload-row {
  display: grid;
  grid-template-columns: 130px 1fr 2fr;
  gap: 10px;
  align-items: center;
  padding: 12px;
  background: var(--surface-2);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}

.upload-row > span {
  font-size: 0.85rem;
  color: var(--text-dim);
}

.upload-row input[type="file"] {
  padding: 6px;
  font-size: 0.85rem;
}

@media (max-width: 720px) {
  .upload-row {
    grid-template-columns: 1fr;
  }
}

/* ─── Auth ─── */
.auth-page {
  min-height: 80vh;
  display: flex;
  align-items: center;
}

.auth-shell {
  display: flex;
  justify-content: center;
}

.auth-card {
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  padding: 40px;
  width: 100%;
  max-width: 440px;
}

.auth-title {
  font-size: 2rem;
  margin: 8px 0 8px;
  letter-spacing: -0.03em;
}

.auth-sub {
  color: var(--text-dim);
  margin-bottom: 24px;
}

.auth-switch {
  margin-top: 20px;
  text-align: center;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.auth-switch a { color: var(--accent-2); font-weight: 600; }

/* ─── Assistant page ─── */
.assistant-page { padding: 32px 0 64px; min-height: calc(100vh - 80px); }

.assistant-shell {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 32px;
  align-items: start;
}

.assistant-side {
  position: sticky;
  top: 100px;
}

.assistant-title {
  font-size: 1.6rem;
  margin: 4px 0 8px;
  letter-spacing: -0.03em;
}

.assistant-sub {
  color: var(--text-dim);
  font-size: 0.92rem;
  margin-bottom: 24px;
}

.suggest-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 20px;
}

.suggest-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.suggest {
  text-align: left;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text-dim);
  font-size: 0.88rem;
  transition: all 0.2s var(--ease);
}

.suggest:hover {
  color: var(--text);
  border-color: var(--accent-glow);
  background: var(--surface-2);
}

.assistant-main {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  height: calc(100vh - 140px);
  min-height: 540px;
  overflow: hidden;
}

.chat {
  flex: 1;
  overflow-y: auto;
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.msg {
  display: flex;
  gap: 12px;
  max-width: 92%;
}

.msg-user { align-self: flex-end; flex-direction: row-reverse; }

.msg-avatar {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--surface-3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--text-dim);
}

.msg-bot .msg-avatar {
  background: linear-gradient(135deg, var(--accent), #ec4899);
  color: var(--text);
}

.msg-body {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 14px 16px;
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--text);
  word-wrap: break-word;
  overflow-wrap: anywhere;
}

.msg-user .msg-body {
  background: var(--accent);
  border-color: var(--accent);
  color: white;
}

.msg-body p + p { margin-top: 8px; }
.msg-body h3, .msg-body h4 { margin: 12px 0 6px; font-size: 1rem; }
.msg-body ul { margin: 8px 0 8px 20px; }
.msg-body li { margin-bottom: 4px; }
.msg-body a { color: var(--accent-2); text-decoration: underline; }
.msg-user .msg-body a { color: white; text-decoration: underline; }
.msg-body code {
  background: var(--surface-3);
  padding: 2px 6px;
  border-radius: 4px;
  font-family: var(--font-mono);
  font-size: 0.85em;
}
.msg-body .err { color: var(--danger); }

.typing {
  display: inline-flex;
  gap: 6px;
  padding: 4px 2px;
}
.typing span {
  width: 8px;
  height: 8px;
  background: var(--text-muted);
  border-radius: 50%;
  animation: typing 1.2s infinite;
}
.typing span:nth-child(2) { animation-delay: 0.2s; }
.typing span:nth-child(3) { animation-delay: 0.4s; }

@keyframes typing {
  0%, 60%, 100% { opacity: 0.3; transform: translateY(0); }
  30% { opacity: 1; transform: translateY(-3px); }
}

.composer {
  display: flex;
  gap: 10px;
  padding: 16px;
  border-top: 1px solid var(--border);
  background: var(--surface);
}

.composer textarea {
  flex: 1;
  min-height: 48px;
  max-height: 220px;
  resize: none;
  background: var(--surface-2);
  border-radius: var(--radius-sm);
}

.composer-hint {
  padding: 8px 28px 16px;
  font-size: 0.78rem;
  color: var(--text-muted);
  background: var(--surface);
}

@media (max-width: 880px) {
  .assistant-shell { grid-template-columns: 1fr; }
  .assistant-side { position: static; }
  .assistant-main { height: 70vh; min-height: 480px; }
}

/* ─── Admin ─── */
.admin-page { padding: 32px 0 80px; }

.admin-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 24px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

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

.admin-stat {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 8px 14px;
  font-size: 0.85rem;
  color: var(--text-dim);
}

.admin-stat strong {
  color: var(--text);
  font-weight: 700;
  margin-right: 4px;
}

.admin-tabs {
  display: flex;
  gap: 4px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 32px;
  overflow-x: auto;
}

.tab {
  padding: 12px 18px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-dim);
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: all 0.2s var(--ease);
  white-space: nowrap;
}

.tab:hover { color: var(--text); }
.tab-active { color: var(--text); border-bottom-color: var(--accent); }

.tab-panel { animation: fadeIn 0.25s var(--ease); }

@keyframes fadeIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

.panel-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.panel-head h2 { font-size: 1.4rem; }

.table-wrap {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 700px;
}

.data-table th,
.data-table td {
  padding: 14px 16px;
  text-align: left;
  font-size: 0.92rem;
  border-bottom: 1px solid var(--border);
}

.data-table th {
  background: var(--surface-2);
  color: var(--text-dim);
  font-weight: 500;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.data-table tbody tr:hover { background: var(--surface-2); }
.data-table tbody tr:last-child td { border-bottom: none; }

.row-actions {
  display: flex;
  gap: 6px;
  justify-content: flex-end;
}

.status-pill {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.status-new { background: rgba(124, 92, 255, 0.18); color: var(--accent-2); }
.status-in_progress { background: rgba(251, 191, 36, 0.16); color: var(--warning); }
.status-done { background: rgba(74, 222, 128, 0.16); color: var(--success); }
.status-rejected { background: rgba(248, 113, 113, 0.16); color: var(--danger); }
.status-published { background: rgba(74, 222, 128, 0.16); color: var(--success); }
.status-hidden { background: rgba(248, 113, 113, 0.16); color: var(--danger); }

.screenshots-block {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 16px;
}

.screenshots-block h4 {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  margin-bottom: 12px;
}

.screenshots-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}

.screenshot-item {
  position: relative;
  aspect-ratio: 4 / 3;
  border-radius: 8px;
  overflow: hidden;
  background: var(--surface-3);
  border: 1px solid var(--border);
}

.screenshot-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.screenshot-remove {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(15, 15, 25, 0.85);
  color: var(--text);
  font-size: 1rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.screenshot-remove:hover { background: var(--danger); }

.settings-form { max-width: 640px; }

/* ─── Misc ─── */
.no-scroll { overflow: hidden; }
