﻿/* ============================================================
   style.css — Portfolio Public Website Stylesheet
   Editorial Dark Theme | Light Theme via [data-theme="light"]
   Custom CSS, no framework.
   ============================================================ */

/* ── 1. CSS Custom Properties (Theme Variables) ─────────────── */

:root,
[data-theme="dark"] {
  /* Background layers — warm near-black, not cold gray */
  --color-bg:          #0d0c0b;
  --color-bg-secondary:#111010;
  --color-surface:     #1a1816;
  --color-surface-alt: #221f1c;
  --color-border:      rgba(255, 255, 255, 0.07);
  --color-border-hover:rgba(255, 255, 255, 0.14);

  /* Text — warm cream, not pure white */
  --color-text:        #ede8df;
  --color-text-muted:  #7c776e;
  --color-text-subtle: #3a3630;

  /* Accent — burnt orange / coral, NOT generic purple */
  --color-accent:      #e8612c;
  --color-accent-2:    #d4521f;
  --color-accent-glow: rgba(232, 97, 44, 0.15);
  --color-accent-light:#f07d4f;

  /* Semantic */
  --color-success:  #4ade80;
  --color-warning:  #fbbf24;
  --color-error:    #f87171;
  --color-info:     #60a5fa;

  /* Navbar */
  --color-navbar-bg: rgba(13, 12, 11, 0.88);

  /* Cards */
  --color-card-bg:    #1a1816;
  --color-card-border:rgba(255, 255, 255, 0.06);

  /* Shadows */
  --shadow-sm:  0 1px 4px rgba(0,0,0,0.5);
  --shadow-md:  0 6px 20px rgba(0,0,0,0.55);
  --shadow-lg:  0 20px 60px rgba(0,0,0,0.65);
  --shadow-accent: 0 0 40px rgba(232, 97, 44, 0.2);

  /* Code syntax */
  --code-keyword: #f97316;
  --code-var:     #60a5fa;
  --code-str:     #4ade80;
  --code-key:     #ede8df;
  --code-op:      #7c776e;

  --theme-transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

[data-theme="light"] {
  --color-bg:          #f5f0e8;
  --color-bg-secondary:#ede8de;
  --color-surface:     #ffffff;
  --color-surface-alt: #f8f4ed;
  --color-border:      rgba(0, 0, 0, 0.08);
  --color-border-hover:rgba(0, 0, 0, 0.16);

  --color-text:        #1a1614;
  --color-text-muted:  #6b6460;
  --color-text-subtle: #b0a89e;

  --color-accent:      #e8612c;
  --color-accent-2:    #d4521f;
  --color-accent-glow: rgba(232, 97, 44, 0.1);
  --color-accent-light:#c94e20;

  --color-navbar-bg: rgba(245, 240, 232, 0.92);

  --color-card-bg:    #ffffff;
  --color-card-border:rgba(0, 0, 0, 0.07);

  --shadow-sm:  0 1px 4px rgba(0,0,0,0.07);
  --shadow-md:  0 6px 20px rgba(0,0,0,0.1);
  --shadow-lg:  0 20px 60px rgba(0,0,0,0.12);
  --shadow-accent: 0 0 40px rgba(232, 97, 44, 0.12);

  --code-keyword: #c2410c;
  --code-var:     #1d4ed8;
  --code-str:     #15803d;
  --code-key:     #1a1614;
  --code-op:      #6b6460;
}

/* ── 2. Reset & Base ─────────────────────────────────────────── */

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background-color: var(--color-bg);
  color: var(--color-text);
  line-height: 1.6;
  min-height: 100vh;
  transition: var(--theme-transition);
  overflow-x: hidden;
}

/* Space Grotesk for all headings */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Space Grotesk', 'Inter', system-ui, sans-serif;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--color-accent-light);
  text-decoration: none;
  transition: color 0.2s ease, opacity 0.2s ease;
}
a:hover { opacity: 0.8; }

button { font-family: inherit; cursor: pointer; }

ul { list-style: none; }

/* ── 3. Layout Utilities ─────────────────────────────────────── */

.container {
  width: 100%;
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section {
  padding: 7rem 0;
}

.page-main {
  padding-top: 72px;
  min-height: calc(100vh - 72px);
}

/* ── 4. Section Headers ──────────────────────────────────────── */

.section-header {
  text-align: center;
  margin-bottom: 4rem;
}

/* The label — editorial line style, not a pill badge */
.section-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-accent-light);
  margin-bottom: 0.9rem;
}

.section-tag::before {
  content: '';
  display: inline-block;
  width: 24px;
  height: 2px;
  background: var(--color-accent);
  flex-shrink: 0;
}

.section-title {
  font-size: clamp(1.9rem, 4.5vw, 3rem);
  font-weight: 700;
  line-height: 1.15;
  color: var(--color-text);
  margin-bottom: 0.75rem;
  letter-spacing: -0.025em;
}

.section-subtitle {
  font-size: 1rem;
  color: var(--color-text-muted);
  max-width: 520px;
  margin: 0 auto;
  line-height: 1.7;
}

/* ── 5. Buttons ──────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 1.4rem;
  border-radius: 0.4rem;
  font-size: 0.875rem;
  font-weight: 600;
  font-family: 'Space Grotesk', 'Inter', sans-serif;
  border: 1.5px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s ease;
  white-space: nowrap;
  line-height: 1;
  letter-spacing: 0.01em;
}

.btn:hover { opacity: 1; }

.btn--primary {
  background: var(--color-accent);
  color: #fff;
  border-color: var(--color-accent);
}
.btn--primary:hover {
  background: var(--color-accent-2);
  border-color: var(--color-accent-2);
  box-shadow: 0 4px 24px var(--color-accent-glow);
  transform: translateY(-1px);
}

.btn--outline {
  background: transparent;
  color: var(--color-text);
  border-color: var(--color-border-hover);
}
.btn--outline:hover {
  border-color: var(--color-accent);
  color: var(--color-accent-light);
  background: var(--color-accent-glow);
}

.btn--secondary {
  background: var(--color-surface-alt);
  color: var(--color-text);
  border-color: var(--color-border);
}
.btn--secondary:hover {
  border-color: var(--color-accent);
  color: var(--color-accent-light);
}

.btn--danger {
  background: transparent;
  color: var(--color-error);
  border-color: var(--color-error);
}
.btn--danger:hover {
  background: var(--color-error);
  color: #fff;
}

.btn--lg  { padding: 0.875rem 1.875rem; font-size: 0.95rem; }
.btn--sm  { padding: 0.4rem 0.85rem; font-size: 0.78rem; border-radius: 0.3rem; }
.btn--full { width: 100%; justify-content: center; }

/* ── 6. Navbar ───────────────────────────────────────────────── */

.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--color-navbar-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--color-border);
  height: 68px;
  transition: var(--theme-transition), box-shadow 0.3s ease;
}

.navbar.scrolled {
  box-shadow: var(--shadow-md);
}

.navbar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.navbar__brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 700;
  font-size: 1.05rem;
  font-family: 'Space Grotesk', 'Inter', sans-serif;
  color: var(--color-text);
  text-decoration: none;
  letter-spacing: -0.01em;
}
.navbar__brand:hover { opacity: 1; }

/* Orange dot brand mark — replaces emoji */
.navbar__brand-symbol {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--color-accent);
  flex-shrink: 0;
  display: block;
}

.navbar__links {
  display: flex;
  align-items: center;
  gap: 0;
}

.navbar__link {
  padding: 0.5rem 0.9rem;
  border-radius: 0.35rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--color-text-muted);
  text-decoration: none;
  transition: all 0.2s ease;
  letter-spacing: 0.005em;
}
.navbar__link:hover,
.navbar__link--active {
  color: var(--color-text);
  background: var(--color-surface-alt);
  opacity: 1;
}

.navbar__controls {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Theme toggle */
.theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px; height: 36px;
  border-radius: 0.4rem;
  border: 1px solid var(--color-border);
  background: transparent;
  color: var(--color-text-muted);
  cursor: pointer;
  transition: all 0.2s ease;
}
.theme-toggle:hover {
  color: var(--color-text);
  border-color: var(--color-accent);
  background: var(--color-accent-glow);
}

[data-theme="dark"]  .theme-toggle__icon--moon { display: block; }
[data-theme="dark"]  .theme-toggle__icon--sun  { display: none;  }
[data-theme="light"] .theme-toggle__icon--moon { display: none;  }
[data-theme="light"] .theme-toggle__icon--sun  { display: block; }

/* Hamburger */
.navbar__hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px; height: 36px;
  background: none;
  border: 1px solid var(--color-border);
  border-radius: 0.4rem;
  padding: 8px;
  cursor: pointer;
}
.navbar__hamburger span {
  display: block;
  width: 100%;
  height: 1.5px;
  background: var(--color-text-muted);
  border-radius: 2px;
  transition: all 0.3s ease;
}
.navbar__hamburger.active span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.navbar__hamburger.active span:nth-child(2) { opacity: 0; }
.navbar__hamburger.active span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* ── 7. Hero Section ─────────────────────────────────────────── */

.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 7rem 0 5rem;
  position: relative;
  overflow: hidden;
}

/* Subtle warm glow — off-center, feels natural */
.hero::before {
  content: '';
  position: absolute;
  top: 5%;
  left: -8%;
  width: 560px;
  height: 560px;
  background: radial-gradient(ellipse, rgba(232,97,44,0.07) 0%, transparent 65%);
  pointer-events: none;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--color-border);
}

.hero__inner {
  display: grid;
  grid-template-columns: 1fr 380px;
  align-items: center;
  gap: 5rem;
}

.hero__greeting {
  margin-bottom: 1.25rem;
}

/* Eyebrow label — editorial style */
.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-accent-light);
  background: none;
  border: none;
  padding: 0;
  border-radius: 0;
}

.hero__badge::before {
  content: '';
  display: inline-block;
  width: 20px;
  height: 2px;
  background: var(--color-accent);
  flex-shrink: 0;
}

.hero__name {
  font-size: clamp(3rem, 8vw, 5.5rem);
  font-weight: 700;
  line-height: 1.0;
  color: var(--color-text);
  margin-bottom: 1rem;
  letter-spacing: -0.04em;
}

.hero__role {
  font-family: 'JetBrains Mono', monospace;
  font-size: clamp(0.85rem, 2vw, 1rem);
  color: var(--color-text-muted);
  margin-bottom: 2rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.hero__role-prefix,
.hero__role-suffix {
  color: var(--color-accent);
  opacity: 0.55;
}

.hero__bio {
  font-size: 1.05rem;
  color: var(--color-text-muted);
  max-width: 460px;
  margin-bottom: 2.75rem;
  line-height: 1.75;
}

.hero__ctas {
  display: flex;
  gap: 0.875rem;
  flex-wrap: wrap;
}

/* Avatar — clean rounded rectangle, no rings or decorations */
.hero__visual {
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}

.hero__avatar-wrapper {
  position: relative;
  width: 340px;
  height: 380px;
}

.hero__avatar {
  width: 100%;
  height: 100%;
  border-radius: 1.25rem;
  object-fit: cover;
  object-position: top;
  border: 1px solid var(--color-border);
  position: relative;
  z-index: 2;
  display: block;
  filter: grayscale(15%);
  transition: filter 0.5s ease;
}

.hero__avatar:hover {
  filter: grayscale(0%);
}

/* Hide the spinning ring & dots — these are AI slop */
.hero__avatar-ring,
.hero__avatar-dots {
  display: none;
}

/* Hide the floating code badge — also AI slop */
.hero__code-badge {
  display: none;
}

/* Scroll indicator */
.hero__scroll-indicator {
  position: absolute;
  bottom: 2.5rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  color: var(--color-text-subtle);
  text-decoration: none;
}
.hero__scroll-indicator span {
  display: block;
  width: 1px;
  height: 48px;
  background: linear-gradient(to bottom, var(--color-accent), transparent);
  animation: scrollPulse 2s ease-in-out infinite;
}
@keyframes scrollPulse {
  0%, 100% { opacity: 0.2; transform: scaleY(0.7); }
  50%       { opacity: 0.7; transform: scaleY(1); }
}

/* ── 8. About Section ────────────────────────────────────────── */

.about {
  background: var(--color-bg-secondary);
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

.about__inner {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 6rem;
  align-items: center;
}

.about__image-wrapper {
  position: relative;
}

.about__image {
  width: 100%;
  max-width: 280px;
  border-radius: 1rem;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-md);
  filter: grayscale(15%);
  transition: filter 0.5s ease;
}

.about__image:hover {
  filter: grayscale(0%);
}

/* Offset accent border behind image */
.about__image-wrapper::after {
  content: '';
  position: absolute;
  inset: 10px -10px -10px 10px;
  border-radius: 1rem;
  border: 1px solid var(--color-accent);
  opacity: 0.2;
  z-index: -1;
  pointer-events: none;
}

.about__name {
  font-size: 1.875rem;
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: 0.2rem;
  letter-spacing: -0.02em;
}

.about__role {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.82rem;
  color: var(--color-accent-light);
  margin-bottom: 1.75rem;
  opacity: 0.8;
}

.about__bio p {
  color: var(--color-text-muted);
  line-height: 1.85;
  margin-bottom: 1rem;
  font-size: 1rem;
}

.about__actions {
  display: flex;
  gap: 0.875rem;
  margin-top: 2rem;
  flex-wrap: wrap;
}

/* ── 9. Skills Section ───────────────────────────────────────── */

.skills {
  background: var(--color-bg);
}

.skills-group {
  margin-bottom: 2.5rem;
}

.skills-group__title {
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--color-text-subtle);
  margin-bottom: 1rem;
  padding-bottom: 0;
  border-bottom: none;
}

/* Pill tags — not icon-grid cards */
.skills-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.skill-item {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.45rem 0.95rem;
  background: var(--color-surface);
  border: 1px solid var(--color-card-border);
  border-radius: 2rem;
  cursor: default;
  transition: all 0.2s ease;
}

.skill-item:hover {
  border-color: rgba(232, 97, 44, 0.45);
  background: var(--color-surface-alt);
  transform: translateY(-2px);
}

.skill-item__icon {
  color: var(--color-accent-light);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.skill-item__icon svg {
  width: 16px;
  height: 16px;
}

.skill-item__label {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--color-text-muted);
  transition: color 0.2s ease;
  white-space: nowrap;
}

.skill-item:hover .skill-item__label {
  color: var(--color-text);
}

/* ── 10. Featured Source Code ────────────────────────────────── */

.featured {
  background: var(--color-bg-secondary);
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

.products-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.featured__cta {
  text-align: center;
  margin-top: 3rem;
}

/* ── 11. Product Card ────────────────────────────────────────── */

.product-card {
  background: var(--color-card-bg);
  border: 1px solid var(--color-card-border);
  border-radius: 0.75rem;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all 0.25s ease;
}

.product-card:hover {
  transform: translateY(-5px);
  border-color: rgba(232, 97, 44, 0.35);
  box-shadow: var(--shadow-md);
}

.product-card__media {
  display: block;
  overflow: hidden;
  aspect-ratio: 16/9;
  background: var(--color-surface-alt);
}

.product-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.product-card:hover .product-card__img {
  transform: scale(1.05);
}

.product-card__img--placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text-subtle);
  width: 100%;
  height: 100%;
}

.product-card__body {
  padding: 1.25rem;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}

.product-card__title {
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.01em;
}
.product-card__title a {
  color: var(--color-text);
  text-decoration: none;
}
.product-card__title a:hover {
  color: var(--color-accent-light);
  opacity: 1;
}

.product-card__desc {
  font-size: 0.84rem;
  color: var(--color-text-muted);
  line-height: 1.55;
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
}

.product-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--color-border);
  margin-top: auto;
}

.product-card__price {
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--color-accent-light);
  font-family: 'JetBrains Mono', monospace;
}

/* ── 12. Tags ────────────────────────────────────────────────── */

.tag {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 500;
  padding: 0.2rem 0.55rem;
  background: var(--color-surface-alt);
  color: var(--color-text-muted);
  border: 1px solid var(--color-border);
  border-radius: 0.25rem;
  transition: all 0.2s ease;
}
.tag:hover { color: var(--color-text); border-color: var(--color-border-hover); }
.tag--more { font-style: italic; opacity: 0.6; }
.tag--lg   { padding: 0.3rem 0.85rem; font-size: 0.78rem; border-radius: 0.35rem; }

/* ── 13. Contact Section ─────────────────────────────────────── */

.contact {
  background: var(--color-bg);
}

.contact-links {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.875rem;
  max-width: 760px;
  margin: 0 auto;
}

.contact-card {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  padding: 1.25rem 1.5rem;
  background: var(--color-surface);
  border: 1px solid var(--color-card-border);
  border-radius: 0.75rem;
  color: var(--color-text);
  text-decoration: none;
  transition: all 0.2s ease;
}

.contact-card:hover {
  border-color: rgba(232, 97, 44, 0.4);
  background: var(--color-surface-alt);
  transform: translateX(5px);
  box-shadow: var(--shadow-sm);
  opacity: 1;
}

.contact-card__icon {
  width: 44px; height: 44px;
  border-radius: 0.6rem;
  background: var(--color-surface-alt);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text-muted);
  flex-shrink: 0;
  transition: all 0.2s ease;
}

.contact-card:hover .contact-card__icon {
  background: var(--color-accent-glow);
  color: var(--color-accent-light);
}

.contact-card__icon--instagram { }
.contact-card__icon--email { }
.contact-card__icon--whatsapp { }

.contact-card__info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.contact-card__platform {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--color-text);
  font-family: 'Space Grotesk', 'Inter', sans-serif;
  letter-spacing: -0.01em;
}

.contact-card__action {
  font-size: 0.78rem;
  color: var(--color-text-muted);
}

.contact-card__arrow {
  color: var(--color-text-subtle);
  transition: transform 0.2s ease, color 0.2s ease;
  flex-shrink: 0;
}
.contact-card:hover .contact-card__arrow {
  transform: translateX(4px);
  color: var(--color-accent-light);
}

/* ── 14. Footer ──────────────────────────────────────────────── */

.site-footer {
  border-top: 1px solid var(--color-border);
  background: var(--color-bg-secondary);
  padding: 2rem 0;
}

.site-footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.site-footer__brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 700;
  font-family: 'Space Grotesk', 'Inter', sans-serif;
  color: var(--color-text);
  letter-spacing: -0.01em;
}

.site-footer__logo {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-accent);
  flex-shrink: 0;
  display: block;
  font-size: 0; /* hide any text */
}

.site-footer__copy {
  font-size: 0.78rem;
  color: var(--color-text-muted);
}

.site-footer__links {
  display: flex;
  gap: 1.5rem;
}

.site-footer__link {
  font-size: 0.78rem;
  color: var(--color-text-muted);
  text-decoration: none;
  transition: color 0.2s ease;
}
.site-footer__link:hover {
  color: var(--color-text);
  opacity: 1;
}

/* ── 15. Source Code Listing Page ────────────────────────────── */

.page-header {
  text-align: center;
  margin-bottom: 3.5rem;
  padding-top: 2rem;
}

.page-header__title {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 1rem;
}

.page-header__subtitle {
  font-size: 1rem;
  color: var(--color-text-muted);
  max-width: 520px;
  margin: 0 auto;
}

.listing-meta {
  text-align: right;
  font-size: 0.82rem;
  color: var(--color-text-muted);
  margin-bottom: 1.5rem;
}

/* ── 16. Pagination ──────────────────────────────────────────── */

.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  margin-top: 3rem;
  flex-wrap: wrap;
}

.pagination__btn {
  padding: 0.5rem 1rem;
  border-radius: 0.35rem;
  font-size: 0.82rem;
  font-weight: 600;
  text-decoration: none;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  color: var(--color-text);
  transition: all 0.2s ease;
}
.pagination__btn:hover {
  border-color: var(--color-accent);
  color: var(--color-accent-light);
  opacity: 1;
}

.pagination__btn--disabled {
  opacity: 0.3;
  pointer-events: none;
}

.pagination__pages {
  display: flex;
  gap: 0.3rem;
}

.pagination__page {
  width: 34px; height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.35rem;
  font-size: 0.82rem;
  font-weight: 600;
  text-decoration: none;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  color: var(--color-text-muted);
  transition: all 0.2s ease;
}
.pagination__page:hover {
  border-color: var(--color-accent);
  color: var(--color-accent-light);
  opacity: 1;
}
.pagination__page--active {
  background: var(--color-accent);
  border-color: var(--color-accent);
  color: #fff;
}

.pagination__ellipsis {
  display: flex;
  align-items: center;
  color: var(--color-text-muted);
  padding: 0 0.25rem;
}

/* ── 17. Product Detail ──────────────────────────────────────── */

.breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: var(--color-text-muted);
  margin-bottom: 2.5rem;
  flex-wrap: wrap;
}

.breadcrumb__link {
  color: var(--color-text-muted);
  text-decoration: none;
}
.breadcrumb__link:hover { color: var(--color-text); opacity: 1; }
.breadcrumb__sep { color: var(--color-text-subtle); }
.breadcrumb__current { color: var(--color-text); }

.product-detail__inner {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
  gap: 3rem;
  align-items: start;
}

.product-detail__sidebar {
  position: sticky;
  top: 88px;
}

.product-detail__name {
  font-size: clamp(1.5rem, 4vw, 2.25rem);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1rem;
  letter-spacing: -0.025em;
}

.product-detail__short-desc {
  font-size: 1rem;
  color: var(--color-text-muted);
  line-height: 1.7;
  margin-bottom: 1.25rem;
}

.product-detail__techs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 2rem;
}

.product-detail__section {
  margin-bottom: 2.5rem;
}

.product-detail__section-title {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--color-border);
  letter-spacing: -0.01em;
}

.product-detail__description {
  color: var(--color-text-muted);
  line-height: 1.8;
}

.feature-list { display: flex; flex-direction: column; gap: 0.6rem; }

.feature-list__item {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  font-size: 0.9rem;
  color: var(--color-text-muted);
}
.feature-list__item svg {
  color: var(--color-success);
  flex-shrink: 0;
  margin-top: 2px;
}

.product-detail__meta {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid var(--color-border);
}

.product-detail__meta-item {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.78rem;
  color: var(--color-text-subtle);
}

/* ── 18. Gallery ─────────────────────────────────────────────── */

.gallery {
  border-radius: 0.75rem;
  overflow: hidden;
  margin-bottom: 1.5rem;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
}

.gallery__main {
  position: relative;
  aspect-ratio: 16/9;
  cursor: zoom-in;
  overflow: hidden;
}

.gallery__main-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.gallery__main:hover .gallery__main-img {
  transform: scale(1.02);
}

.gallery__nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0,0,0,0.55);
  color: #fff;
  border: none;
  width: 36px; height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 2;
  font-size: 1rem;
  transition: background 0.2s ease;
}
.gallery__nav:hover { background: var(--color-accent); }
.gallery__nav--prev { left: 0.75rem; }
.gallery__nav--next { right: 0.75rem; }

.gallery__thumbs {
  display: flex;
  gap: 0.5rem;
  padding: 0.75rem;
  overflow-x: auto;
  scrollbar-width: thin;
}

.gallery__thumb {
  flex-shrink: 0;
  width: 60px; height: 45px;
  border-radius: 0.35rem;
  overflow: hidden;
  border: 2px solid var(--color-border);
  cursor: pointer;
  background: none;
  padding: 0;
  transition: all 0.2s ease;
  opacity: 0.6;
}
.gallery__thumb:hover,
.gallery__thumb--active {
  border-color: var(--color-accent);
  opacity: 1;
}
.gallery__thumb img {
  width: 100%; height: 100%;
  object-fit: cover;
}

/* ── 19. Lightbox ────────────────────────────────────────────── */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lightbox__overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.92);
  cursor: pointer;
}

.lightbox__img {
  position: relative;
  z-index: 1;
  max-width: 90vw;
  max-height: 85vh;
  object-fit: contain;
  border-radius: 0.5rem;
}

.lightbox__close {
  position: absolute;
  top: 1rem; right: 1rem;
  width: 40px; height: 40px;
  background: rgba(255,255,255,0.08);
  border: none;
  border-radius: 50%;
  color: #fff;
  font-size: 1.1rem;
  cursor: pointer;
  z-index: 2;
  transition: background 0.2s ease;
}
.lightbox__close:hover { background: var(--color-accent); }

.lightbox__nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255,255,255,0.08);
  border: none;
  color: #fff;
  width: 48px; height: 48px;
  border-radius: 50%;
  font-size: 1.2rem;
  cursor: pointer;
  z-index: 2;
  transition: background 0.2s ease;
}
.lightbox__nav:hover { background: var(--color-accent); }
.lightbox__nav--prev { left: 1rem; }
.lightbox__nav--next { right: 1rem; }

.lightbox__counter {
  position: absolute;
  bottom: 1rem;
  left: 50%;
  transform: translateX(-50%);
  color: rgba(255,255,255,0.6);
  font-size: 0.78rem;
  z-index: 2;
}

/* ── 20. Purchase Card ───────────────────────────────────────── */

.purchase-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 0.75rem;
  padding: 1.5rem;
}

.purchase-card__price {
  font-family: 'JetBrains Mono', monospace;
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--color-accent-light);
  margin-bottom: 1rem;
}

.purchase-card__note {
  font-size: 0.75rem;
  color: var(--color-text-muted);
  text-align: center;
  margin-top: 0.75rem;
  line-height: 1.5;
}

.purchase-card__no-url {
  text-align: center;
  color: var(--color-text-muted);
  font-size: 0.85rem;
  padding: 1rem;
  background: var(--color-surface-alt);
  border-radius: 0.5rem;
}

/* ── 21. 404 / Error Page ────────────────────────────────────── */

.error-page { text-align: center; }

.error-page__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 6rem 0;
}

.error-page__code {
  font-size: clamp(5rem, 20vw, 10rem);
  font-weight: 700;
  color: var(--color-accent);
  line-height: 1;
  opacity: 0.1;
  font-family: 'JetBrains Mono', monospace;
}

.error-page__title {
  font-size: clamp(1.5rem, 4vw, 2.5rem);
  font-weight: 700;
  margin-bottom: 1rem;
  margin-top: -2rem;
  letter-spacing: -0.02em;
}

.error-page__message {
  color: var(--color-text-muted);
  max-width: 420px;
  margin-bottom: 2rem;
  line-height: 1.7;
}

.error-page__actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  justify-content: center;
}

.error-page__code-snippet {
  margin-top: 3rem;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 0.75rem;
  padding: 1.25rem 2rem;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.82rem;
  color: var(--code-op);
}

/* ── 22. Empty State ─────────────────────────────────────────── */

.empty-state {
  text-align: center;
  padding: 4rem 2rem;
  color: var(--color-text-muted);
}
.empty-state h2 { margin: 1.5rem 0 0.75rem; font-size: 1.2rem; letter-spacing: -0.01em; }
.empty-state p { margin-bottom: 1.5rem; }

/* ── 23. Reveal Animations ───────────────────────────────────── */

[data-reveal] {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}

[data-reveal].revealed {
  opacity: 1;
  transform: translateY(0);
}

[data-reveal-delay="150"] { transition-delay: 0.15s; }
[data-reveal-delay="200"] { transition-delay: 0.2s;  }
[data-reveal-delay="300"] { transition-delay: 0.3s;  }

/* ── 24. Responsive — Tablet (≤1024px) ──────────────────────── */

@media (max-width: 1024px) {
  .hero__inner {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 3.5rem;
  }
  .hero__badge { justify-content: center; }
  .hero__bio { margin: 0 auto 2.5rem; max-width: 520px; }
  .hero__ctas { justify-content: center; }
  .hero__visual { order: -1; }
  .hero__avatar-wrapper {
    width: 220px; height: 250px;
    margin: 0 auto;
  }

  .about__inner {
    grid-template-columns: 1fr;
    gap: 3rem;
    text-align: center;
  }
  .about__image {
    max-width: 240px;
    margin: 0 auto;
  }
  .about__image-wrapper::after { display: none; }
  .about__actions { justify-content: center; }

  .products-grid { grid-template-columns: repeat(2, 1fr); }

  .contact-links { grid-template-columns: repeat(2, 1fr); }

  .product-detail__inner { grid-template-columns: 1fr; }
  .product-detail__sidebar { position: static; }
}

/* ── 25. Responsive — Mobile (≤768px) ────────────────────────── */

@media (max-width: 768px) {
  .section { padding: 4.5rem 0; }

  .navbar__links {
    position: fixed;
    top: 68px;
    left: 0; right: 0;
    background: var(--color-navbar-bg);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--color-border);
    flex-direction: column;
    align-items: flex-start;
    padding: 1rem 1.5rem;
    gap: 0.15rem;
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s ease;
    z-index: 999;
  }
  .navbar__links.menu-open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }
  .navbar__link {
    width: 100%;
    padding: 0.75rem 1rem;
    font-size: 0.95rem;
  }
  .navbar__hamburger { display: flex; }

  .products-grid { grid-template-columns: 1fr; }

  .contact-links { grid-template-columns: 1fr; }
  .contact-card:hover { transform: translateY(-2px); }

  .site-footer__inner {
    flex-direction: column;
    text-align: center;
  }
}

/* ── 26. Responsive — Small Mobile (≤480px) ──────────────────── */

@media (max-width: 480px) {
  .hero__name { font-size: 2.6rem; }
  .hero__ctas { flex-direction: column; }
  .hero__ctas .btn { width: 100%; justify-content: center; }

  .about__actions { flex-direction: column; }

  .section-title { font-size: 1.7rem; }

  .skills-grid { gap: 0.5rem; }

  .product-detail__inner { gap: 2rem; }

  .error-page__actions { flex-direction: column; align-items: center; }
}

/* ── 27. Code syntax highlight classes ───────────────────────── */
.code-keyword { color: var(--code-keyword); }
.code-var     { color: var(--code-var); }
.code-str     { color: var(--code-str); }
.code-key     { color: var(--code-key); }
.code-op      { color: var(--code-op); }

