/* ArtGabi */

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

:root {
  --bg:        #fbfaf6;
  --bg-alt:    #f3f1e9;
  --bg-alt2:   #ece9de;
  --panel:     #ffffff;
  --ink:       #1c1b16;
  --text:      #33312a;
  --dim:       #726c5d;
  --border:    #e2ddcd;
  --border-soft: rgba(28,27,22,0.08);
  --accent:    #2a4fbf;
  --accent-ink:#1c3690;
  --link:      #2a4fbf;
  --danger:    #b23b3b;

  --serif: 'Lora', Georgia, 'Times New Roman', serif;
  --sans: 'Source Sans 3', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  color-scheme: light;
}

:root[data-theme="dark"] {
  --bg:        #10121a;
  --bg-alt:    #161826;
  --bg-alt2:   #1b1e2e;
  --panel:     #141726;
  --ink:       #f4f2e8;
  --text:      #d6d3c7;
  --dim:       #8b8fa6;
  --border:    rgba(255,255,255,0.10);
  --border-soft: rgba(255,255,255,0.06);
  --accent:    #dba449;
  --accent-ink:#f0bd63;
  --link:      #7ea0ff;

  color-scheme: dark;
}

html, body { height: 100%; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }

.wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 2rem;
}

h1, h2, h3 { font-family: var(--serif); color: var(--ink); font-weight: 500; line-height: 1.2; }

.eyebrow {
  display: block;
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.7rem;
}

/* ═══════════ TOPBAR ═══════════ */
:root {
  --topbar-bg:     #387071;
  --topbar-ink:    #f7f5ec;
  --topbar-dim:    rgba(247,245,236,0.72);
  --topbar-border: rgba(247,245,236,0.16);
  --topbar-accent: #e3b466;
}

.topbar {
  border-bottom: 1px solid var(--topbar-border);
  background: var(--topbar-bg);
  position: sticky;
  top: 0;
  z-index: 100;
}
.topbar-inner {
  display: flex;
  align-items: center;
  gap: 2.5rem;
  height: 120px;
}

.brand { display: flex; align-items: center; white-space: nowrap; }
.logo { height: 100px; width: auto; display: block; }
.logo-bottom { height: 50px; width: auto; display: block; }

.brand-name {
  font-family: var(--serif);
  font-size: 1.5rem;
  color: var(--topbar-ink);
}
.brand-name em { font-style: italic; color: var(--topbar-accent); }
.brand-tag {
  font-size: 0.6rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--topbar-dim);
  margin-top: 0.15rem;
}

.mainnav {
  display: flex;
  list-style: none;
  gap: 1.6rem;
  margin: 0 auto 0 1rem;
  padding: 0;
  flex: 1;
}
.mainnav a {
  position: relative;
  display: inline-block;
  padding: 1.8rem 0 0.75rem;
  font-size: 1.2rem;
  color: var(--topbar-dim);
}
.mainnav a::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: 0.4rem;
  height: 2px;
  background: var(--topbar-accent);
  transform: scaleX(0);
  transition: transform 0.18s ease;
}
.mainnav a:hover { color: var(--topbar-ink); }
.mainnav a.active { color: var(--topbar-accent); }
.mainnav a.active::after { transform: scaleX(1); }

.topbar-right { display: flex; align-items: center; gap: 1.1rem; }

.lang-switch { display: flex; gap: 0.3rem; font-size: 1rem; letter-spacing: 0.06em; }
.lang-switch a { color: var(--topbar-dim); padding: 0.2rem 0.35rem; border-radius: 3px; }
.lang-switch a.active { color: var(--topbar-accent); font-weight: 600; }

.theme-toggle {
  width: 40px; height: 40px;
  display: flex; align-items: center; justify-content: center;
  border: 1px solid var(--topbar-border);
  border-radius: 50%;
  background: transparent;
  color: var(--topbar-dim);
  cursor: pointer;
}
.theme-toggle:hover { color: var(--topbar-accent); border-color: var(--topbar-accent); }
.theme-toggle svg { width: 20px; height: 20px; }
.theme-toggle .icon-moon { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-sun { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-moon { display: block; }

.nav-burger {
  display: none;
  width: 34px; height: 34px;
  border: 1px solid var(--topbar-border);
  border-radius: 4px;
  background: transparent;
  color: var(--topbar-ink);
  font-size: 1.1rem;
  cursor: pointer;
}

/* ═══════════ HERO ═══════════ */
.hero { padding: 4.2rem 0 3.2rem; border-bottom: 1px solid var(--border); }
.hero-inner { max-width: 660px; }
.hero h1 { font-size: 2.6rem; margin: 0 0 1rem; }
.hero p.lead { color: var(--dim); font-size: 1.02rem; max-width: 800px; margin: 0 0 1.4rem; }
.hero-actions { display: flex; align-items: center; gap: 1.6rem; flex-wrap: wrap; }

.link-arrow {
  color: var(--accent);
  font-weight: 600;
  font-size: 0.92rem;
  display: inline-flex; align-items: center; gap: 0.4rem;
}
.link-arrow span { transition: transform 0.15s ease; }
.link-arrow:hover span { transform: translateX(3px); }

.btn-ghost {
  display: inline-flex; align-items: center; gap: 0.5rem;
  border: 1px solid var(--border);
  padding: 0.6rem 1.2rem;
  border-radius: 3px;
  font-size: 0.85rem;
  color: var(--text);
  transition: border-color 0.15s, color 0.15s;
}
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }

/* stats strip (home / www hero) */
.stats-strip {
  display: flex;
  border-top: 1px solid var(--border);
  margin-top: 2.6rem;
}
.stats-strip .stat {
  flex: 1;
  padding: 1.1rem 1.6rem 0 0;
}
.stats-strip .stat + .stat { border-left: 1px solid var(--border); padding-left: 1.6rem; }
.stats-strip .stat-n { font-family: var(--serif); font-size: 1.7rem; color: var(--ink); display: block; }
.stats-strip .stat-l { font-size: 0.8rem; color: var(--dim); }

/* ═══════════ SECTION HEAD ═══════════ */
.section {
  padding: 3.4rem 0;
  border-bottom: 1px solid var(--border);
}
.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.8rem;
  flex-wrap: wrap;
}
.section-head .eyebrow { margin-bottom: 0; }
.section-head h2 { font-size: 1.05rem; font-family: var(--sans); text-transform: uppercase; letter-spacing: 0.08em; font-weight: 600; color: var(--text); margin: 0; }

/* ═══════════ PROJECT GRID ═══════════ */
.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1.6rem;
}
.project-grid.cols-2 { grid-template-columns: repeat(auto-fill, minmax(360px, 1fr)); }

.project-card {
  border: 1px solid var(--border);
  border-radius: 4px;
  background: var(--panel);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: border-color 0.15s;
}
.project-card:hover { border-color: var(--accent); }

.project-card .thumb {
  aspect-ratio: 4 / 3;
  background: var(--bg-alt);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
}
.project-card.is-portrait .thumb { aspect-ratio: 3 / 4; }
.project-card .thumb img { width: 100%; height: 100%; object-fit: cover; }

.project-card .body { padding: 1.2rem 1.3rem 1.3rem; display: flex; flex-direction: column; flex: 1; }

.wip-badge {
  display: inline-block;
  align-self: flex-start;
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  border: 1px solid var(--accent);
  border-radius: 999px;
  padding: 0.15rem 0.6rem;
  margin-bottom: 0.6rem;
}

.project-card .title {
  font-family: var(--serif);
  font-size: 1.08rem;
  color: var(--link);
  margin-bottom: 0.4rem;
}
.project-card .title a { color: inherit; }
.project-card .title a:hover { text-decoration: underline; }

.project-card .desc { color: var(--dim); font-size: 0.88rem; line-height: 1.6; flex: 1; }
.project-card .desc p { margin: 0 0 0.7rem; }
.project-card .desc ul { margin: 0 0 0.7rem; padding-left: 1.1rem; }
.project-card .desc b, .project-card .desc strong { color: var(--text); }

.project-card .foot {
  margin-top: 1rem;
  padding-top: 0.8rem;
  border-top: 1px solid var(--border-soft);
}
.tech-list {
  display: flex; flex-wrap: wrap; gap: 0.3rem 0.5rem;
  font-size: 0.72rem;
  color: var(--dim);
}
.tech-list code { font-family: var(--sans); background: none; }

.store-badges { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 0.7rem; }
.store-badges img { height: 36px; }

.card-links { margin-top: 0.5rem; font-size: 0.85rem; }
.card-links a { color: var(--link); }
.card-links a:hover { text-decoration: underline; }

/* ═══════════ UPDATE FEED (home) ═══════════ */
.update-feed { display: flex; flex-direction: column; }

.update-item {
  display: grid;
  grid-template-columns: 88px 88px 1fr;
  gap: 1.2rem;
  align-items: start;
  padding: 1.4rem 0;
  border-bottom: 1px solid var(--border);
}
.update-item:last-child { border-bottom: none; }

.update-date {
  font-family: var(--sans);
  font-size: 0.78rem;
  color: var(--dim);
  padding-top: 0.3rem;
}

.update-thumb {
  width: 88px;
  aspect-ratio: 4 / 3;
  border-radius: 4px;
  overflow: hidden;
  background: var(--bg-alt);
  border: 1px solid var(--border);
}
.update-thumb img { width: 100%; height: 100%; object-fit: cover; }

.update-tag {
  display: inline-block;
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--link);
  border: 1px solid var(--link);
  border-radius: 999px;
  padding: 0.15rem 0.6rem;
  margin-bottom: 0.5rem;
}

.update-body .title { font-family: var(--serif); font-size: 1.08rem; color: var(--ink); margin-bottom: 0.35rem; }
.update-body .title a { color: inherit; }
.update-body .title a:hover { text-decoration: underline; }
.update-body .desc { color: var(--dim); font-size: 0.9rem; line-height: 1.6; }

@media (max-width: 640px) {
  .update-item { grid-template-columns: 72px 1fr; }
  .update-date { grid-column: 1 / -1; order: -1; padding-top: 0; margin-bottom: 0.3rem; }
}

/* ═══════════ TIMELINE / CALLOUT BOX ═══════════ */
.callout {
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 1.8rem 2rem 0;
  background: var(--bg-alt);
}
.callout .eyebrow { color: var(--link); }
.callout > p { color: var(--dim); max-width: 640px; margin: 0 0 1.6rem; }

.timeline-track {
  display: flex; align-items: center; gap: 0.6rem;
  margin-bottom: 1.8rem;
  color: var(--dim);
  font-size: 0.72rem; letter-spacing: 0.06em; text-transform: uppercase;
}
.timeline-track .line {
  flex: 1; height: 2px; background: var(--link);
  position: relative;
}
.timeline-track .dot {
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--link);
  flex: none;
}
.timeline-track .dot.hollow { background: var(--bg-alt); border: 2px solid var(--link); }
.timeline-track .arrow { color: var(--link); }

.milestones {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.6rem;
  padding-bottom: 1.8rem;
}
.milestone { display: flex; gap: 0.9rem; }
.milestone .m-thumb { width: 56px; height: 56px; border-radius: 4px; overflow: hidden; flex: none; border: 1px solid var(--border); background: var(--panel); }
.milestone .m-thumb img { width: 100%; height: 100%; object-fit: cover; }
.milestone .m-title { color: var(--link); font-weight: 600; font-size: 0.92rem; margin-bottom: 0.2rem; }
.milestone .m-desc { color: var(--dim); font-size: 0.83rem; line-height: 1.55; }
.milestone .m-tech { color: var(--dim); opacity: 0.7; font-size: 0.72rem; margin-top: 0.3rem; }
.milestone .m-thumb.placeholder { display: flex; align-items: center; justify-content: center; color: var(--dim); font-size: 1.2rem; }

.highlight-row {
  display: flex; align-items: center; gap: 1.6rem;
  border-top: 1px solid var(--border);
  padding: 1.6rem 0;
  margin: 0 -2rem;
  padding-left: 2rem; padding-right: 2rem;
  background: var(--panel);
  border-radius: 0 0 4px 4px;
}
.highlight-row .h-thumb { width: 84px; height: 130px; border-radius: 4px; overflow: hidden; flex: none; border: 1px solid var(--border); }
.highlight-row .h-thumb img { width: 100%; height: 100%; object-fit: cover; }
.highlight-row .h-badge {
  width: 46px; height: 46px; border-radius: 50%;
  border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  flex: none; color: var(--link); font-size: 1.1rem;
}
.highlight-row .h-num { font-family: var(--serif); font-size: 1.6rem; color: var(--ink); }
.highlight-row .h-label { font-size: 0.78rem; color: var(--dim); }
.highlight-row .h-note { flex: 1; }
.highlight-row .h-note .m-title { color: var(--link); font-weight: 600; margin-bottom: 0.2rem; }
.highlight-row .h-note .m-desc { color: var(--dim); font-size: 0.85rem; }

/* ═══════════ CTA BAND ═══════════ */
.cta-band { padding: 3.6rem 0; }
.cta-band .wrap { display: flex; align-items: flex-end; justify-content: space-between; gap: 2rem; flex-wrap: wrap; }
.cta-band h2 { font-size: 1.7rem; max-width: 560px; margin: 0 0 0.7rem; }
.cta-band p { color: var(--dim); max-width: 520px; margin: 0 0 1.2rem; }

/* ═══════════ ABOUT / BIO ═══════════ */
.bio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.6rem;
}
.bio-card {
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 1.8rem;
  text-align: center;
}
.bio-card img.portrait {
  width: 108px; height: 108px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid var(--border);
  margin-bottom: 1rem;
}
.bio-card h3 { font-size: 1.15rem; margin: 0 0 0.9rem; }
.bio-line {
  display: flex; align-items: center; justify-content: center; gap: 0.5rem;
  font-size: 0.86rem; color: var(--dim);
  margin-bottom: 0.5rem;
}
.bio-line a { color: var(--link); }
.bio-line a:hover { text-decoration: underline; }
.bio-line ion-icon { color: var(--accent); font-size: 1rem; }

.prose { max-width: 640px; color: var(--text); }
.prose p { margin: 0 0 1rem; }

.company-card {
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 1.8rem 2rem;
  max-width: 420px;
  margin: 0 0 2.4rem;
}
.company-card .name { font-family: var(--serif); font-size: 1.2rem; color: var(--ink); margin-bottom: 0.6rem; }
.company-card .line { font-size: 0.9rem; color: var(--dim); margin-bottom: 0.25rem; }
.company-card a { color: var(--link); }

/* ═══════════ FOOTER ═══════════ */
.site-footer { background: var(--topbar-bg); border-top: 1px solid var(--topbar-border); color: var(--topbar-ink); }
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 2rem;
  padding: 3rem 0 2rem;
}
.footer-grid h4 { font-size: 0.72rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--topbar-dim); margin: 0 0 0.9rem; font-family: var(--sans); font-weight: 600; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0.5rem; }
.footer-grid a { color: var(--topbar-ink); font-size: 0.88rem; }
.footer-grid a:hover { color: var(--topbar-accent); }
.footer-grid p { color: var(--topbar-dim) !important; }
.footer-brand .brand-name { font-size: 1.3rem; color: var(--topbar-ink); }
.footer-brand .brand-name em { color: var(--topbar-accent); }
.footer-brand .brand-tag { color: var(--topbar-dim); margin-top: 0.25rem; margin-bottom: 0.9rem; }
.footer-social { display: flex; gap: 0.5rem; }
.footer-social a {
  width: 30px; height: 30px;
  border: 1px solid var(--topbar-border);
  border-radius: 4px;
  display: flex; align-items: center; justify-content: center;
  color: var(--topbar-ink);
}
.footer-social a:hover { border-color: var(--topbar-accent); color: var(--topbar-accent); }
.footer-social ion-icon, .footer-social img { font-size: 15px; width: 15px; height: 15px; }

.footer-bottom {
  border-top: 1px solid var(--topbar-border);
  padding: 1rem 0;
  display: flex; justify-content: space-between; align-items: center;
  font-size: 0.75rem; color: var(--topbar-dim);
}

/* ═══════════ RESPONSIVE ═══════════ */
@media (max-width: 900px) {
  .mainnav { display: none; }
  .nav-burger { display: flex; align-items: center; justify-content: center; }
  .topbar-inner.nav-open .mainnav {
    display: flex; flex-direction: column; gap: 0;
    position: absolute; top: 110px; left: -20px; right: 0;
    background: var(--topbar-bg); border-bottom: 1px solid var(--topbar-border);
    padding: 0.5rem 2rem 1rem;
  }
  .topbar-inner.nav-open .mainnav a { padding: 0.6rem 0; }
  .topbar-inner.nav-open .mainnav a::after { display: none; }
  .hero h1 { font-size: 2rem; }
  .stats-strip { flex-direction: column; gap: 1rem; }
  .stats-strip .stat + .stat { border-left: none; border-top: 1px solid var(--border); padding-left: 0; padding-top: 1rem; }
  .milestones { grid-template-columns: 1fr; }
  .highlight-row { flex-direction: column; align-items: flex-start; margin: 0 -1.2rem; padding: 1.4rem 1.2rem; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .cta-band .wrap { align-items: flex-start; }
}
@media (max-width: 560px) {
  .wrap { padding: 0 1.2rem; }
  .footer-grid { grid-template-columns: 1fr; }
  .callout { padding: 1.4rem 1.2rem 0; }
  .highlight-row { margin: 0 -1.2rem; }
}
