:root {
  --brand: #1565d8;
  --brand-600: #0d47a1;
  --bg-start: #071029;
  --bg-end: #031026;
  --panel: #071228;
  --card: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(0,0,0,0.05));
  --text: #e6eef8;
  --muted: #9fb3d9;
  --border: rgba(255,255,255,0.06);
  --radius: 12px;
}

* {
  box-sizing: border-box;
}

html, body {
  height: 100%;
  margin: 0;
  font-family: Inter, system-ui, -apple-system, 'Segoe UI', Roboto, Arial;
}

body {
  background: linear-gradient(180deg, var(--bg-start), var(--bg-end));
  color: var(--text);
  -webkit-font-smoothing: antialiased;
}

/* HEADER */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  background: #071029cc;
  backdrop-filter: blur(6px);
  z-index: 1000;
}

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

/* Logo hover */
.brand-logo-container:hover .brand-logo-svg {
  box-shadow: 0 0 12px var(--brand-600);
  transform: scale(1.05);
}

.brand-logo-svg {
  transition: 0.2s ease;
}

.site-name {
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--brand);
  text-transform: lowercase;
}

.tagline {
  font-size: 0.85rem;
  color: var(--muted);
}

/* NAV */
.site-nav a {
  margin-left: 14px;
  color: var(--muted);
  text-decoration: none;
  padding: 8px;
  border-radius: 8px;
  transition: 0.2s;
}

.site-nav a.active,
.site-nav a:hover {
  background: rgba(255,255,255,0.02);
  color: var(--text);
}

/* MAIN */
.shop-main {
  max-width: 1200px;
  margin: 28px auto;
  padding: 0 20px;
}

.hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  background: linear-gradient(90deg, rgba(21,101,216,0.06), rgba(11,116,255,0.02));
  padding: 20px;
  border-radius: 14px;
  border: 1px solid var(--border);
}

.hero h1 {
  margin: 0;
  color: var(--brand);
  font-size: 1.6rem;
}

.hero p {
  margin: 0;
  color: var(--muted);
}

.hero-box {
  width: 160px;
  height: 100px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--border);
  color: var(--muted);
}

/* CONTROLS */
.controls {
  display: flex;
  gap: 12px;
  margin-top: 18px;
  align-items: center;
}

.controls input,
.controls select {
  padding: 10px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text);
}

.controls input {
  flex: 1;
}

.btn-primary {
  background: var(--brand);
  color: white;
  padding: 10px 12px;
  border-radius: 10px;
  border: none;
  cursor: pointer;
}

.btn-outline {
  background: transparent;
  color: var(--text);
  padding: 8px;
  border-radius: 8px;
  border: 1px solid var(--border);
  cursor: pointer;
}

/* PRODUCTS GRID */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
  margin-top: 18px;
}

.product {
  background: var(--card);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  transition: 0.15s ease;
}

.product:hover {
  transform: translateY(-6px);
}

.product img {
  width: 100%;
  height: 160px;
  object-fit: cover;
  background: #051123;
}

.product .info {
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.product h4 {
  margin: 0;
  color: var(--brand);
  font-size: 1.02rem;
}

.product p {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.price-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.actions {
  display: flex;
  gap: 8px;
}

/* MODALS */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1400;
}

.modal-backdrop.visible {
  display: flex;
}

.modal {
  width: 520px;
  max-width: 96vw;
  background: linear-gradient(180deg, #071428, #05102a);
  padding: 18px;
  border-radius: 12px;
  border: 1px solid var(--border);
  position: relative;
}

.close-btn {
  position: absolute;
  right: 12px;
  top: 10px;
  background: transparent;
  border: none;
  color: var(--muted);
  font-size: 18px;
  cursor: pointer;
}

.form-row {
  display: flex;
  gap: 8px;
}

.form-row input,
.form-row textarea {
  flex: 1;
  padding: 10px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text);
}

.modal-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
  margin-top: 10px;
}

/* FOOTER */
.site-footer {
  max-width: 1200px;
  margin: 36px auto 60px;
  padding: 20px;
  color: var(--muted);
}

.footer-top {
  display: flex;
  gap: 24px;
  justify-content: space-between;
  flex-wrap: wrap;
}

.brand-block {
  display: flex;
  gap: 12px;
  max-width: 520px;
}

.brand-block .site-name {
  font-weight: 800;
  color: var(--brand);
  margin-bottom: 6px;
}

.socials {
  margin-top: 8px;
  display: flex;
  gap: 8px;
}

.socials img {
  width: 32px;
  height: 32px;
  opacity: 0.85;
  transition: 0.2s;
}

.socials img:hover {
  opacity: 1;
  transform: scale(1.1);
}

.links-block a {
  color: var(--muted);
  text-decoration: none;
  transition: 0.2s;
}

.links-block a:hover {
  color: var(--brand);
  text-decoration: underline;
}

.footer-bottom {
  margin-top: 18px;
  border-top: 1px solid var(--border);
  padding-top: 12px;
  text-align: center;
}

/* MOBILE FIX */
@media (max-width: 880px) {
  .controls {
    flex-direction: column;
    align-items: stretch;
  }

  .footer-top {
    flex-direction: column;
  }

  .products-grid {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  }
}
