/* ===== Reset & Base ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg: #0a0a0a;
  --bg-elevated: #141414;
  --bg-card: #1a1a1a;
  --border: #262626;
  --border-hover: #404040;
  --text: #fafafa;
  --text-secondary: #a1a1aa;
  --text-muted: #71717a;
  --accent: #3b82f6;
  --accent-soft: rgba(59, 130, 246, 0.12);
  --green: #22c55e;
  --green-soft: rgba(34, 197, 94, 0.12);
  --radius: 12px;
  --radius-sm: 8px;
  --transition: 0.2s ease;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); text-decoration: none; transition: opacity var(--transition); }
a:hover { opacity: 0.8; }

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

.container { max-width: 960px; margin: 0 auto; padding: 0 24px; }

/* ===== Skip Link ===== */
.skip-link {
  position: absolute; top: -100px; left: 8px;
  background: var(--accent); color: #fff;
  padding: 8px 16px; border-radius: var(--radius-sm);
  font-size: 14px; z-index: 200;
}
.skip-link:focus { top: 8px; }

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

.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 64px;
}

.logo {
  width: 36px; height: 36px;
  background: var(--accent);
  color: #fff; font-weight: 700; font-size: 16px;
  border-radius: 10px;
  display: grid; place-items: center;
  text-decoration: none;
  transition: transform var(--transition);
}
.logo:hover { transform: scale(1.05); opacity: 1; }

.nav { display: flex; gap: 4px; }
.nav a {
  padding: 8px 14px; border-radius: var(--radius-sm);
  color: var(--text-secondary); font-size: 14px; font-weight: 500;
  transition: all var(--transition);
}
.nav a:hover { color: var(--text); background: var(--bg-elevated); opacity: 1; }

.nav-toggle {
  display: none; background: none; border: none; cursor: pointer;
  width: 36px; height: 36px;
  flex-direction: column; justify-content: center; align-items: center; gap: 5px;
}
.nav-toggle span {
  display: block; width: 20px; height: 2px; background: var(--text-secondary);
  border-radius: 2px; transition: all var(--transition);
}

/* ===== Hero ===== */
.hero {
  padding: 80px 0 64px;
  border-bottom: 1px solid var(--border);
}

.hero-layout {
  display: flex; gap: 40px; align-items: flex-start;
}

.hero-photo img {
  width: 120px; height: 120px;
  border-radius: 24px; object-fit: cover;
  border: 2px solid var(--border);
}

.hero-text { flex: 1; }

.hero-text h1 {
  font-size: 32px; font-weight: 700; letter-spacing: -0.02em;
  line-height: 1.2; margin-bottom: 4px;
}

.tagline {
  font-size: 16px; font-weight: 500; color: var(--accent);
  margin-bottom: 12px;
}

.intro {
  font-size: 16px; color: var(--text-secondary);
  max-width: 520px; margin-bottom: 16px;
}

.hero-meta { display: flex; gap: 8px; margin-bottom: 24px; }

.chip {
  display: inline-flex; align-items: center;
  padding: 5px 12px; border-radius: 20px;
  font-size: 13px; font-weight: 500;
  background: var(--bg-elevated); border: 1px solid var(--border);
  color: var(--text-secondary);
}

.chip--green {
  background: var(--green-soft); border-color: rgba(34, 197, 94, 0.3);
  color: var(--green);
}

.hero-actions { display: flex; gap: 12px; }

/* ===== Buttons ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 10px 20px; border-radius: var(--radius-sm);
  font-size: 14px; font-weight: 500;
  transition: all var(--transition);
  text-decoration: none; cursor: pointer; border: none;
}

.btn--primary {
  background: var(--accent); color: #fff;
}
.btn--primary:hover { opacity: 0.9; transform: translateY(-1px); }

.btn--ghost {
  background: transparent; color: var(--text-secondary);
  border: 1px solid var(--border);
}
.btn--ghost:hover { border-color: var(--border-hover); color: var(--text); opacity: 1; }

.btn--sm { padding: 7px 14px; font-size: 13px; }

.btn--lg { padding: 14px 28px; font-size: 16px; }

/* ===== Sections ===== */
.section { padding: 64px 0; }

.section--alt { background: var(--bg-elevated); }

.section-title {
  font-size: 24px; font-weight: 700; letter-spacing: -0.02em;
  margin-bottom: 32px;
}

.section-subtitle {
  font-size: 15px; color: var(--text-secondary);
  margin-top: -24px; margin-bottom: 32px;
}

/* ===== About ===== */
.about-grid {
  display: flex; gap: 48px; align-items: flex-start;
  margin-bottom: 32px;
}

.about-text { flex: 1; }
.about-text p {
  color: var(--text-secondary); font-size: 15px; line-height: 1.7;
  margin-bottom: 12px;
}
.about-text p:last-child { margin-bottom: 0; }

.stats {
  display: flex; gap: 32px; flex-shrink: 0;
}

.stat { text-align: center; }
.stat-num {
  display: block; font-size: 28px; font-weight: 700; color: var(--text);
  line-height: 1;
}
.stat-label {
  font-size: 12px; color: var(--text-muted);
  text-transform: uppercase; letter-spacing: 0.05em;
  margin-top: 4px;
}

.skills-bar {
  display: flex; flex-wrap: wrap; gap: 8px;
}

.skill-tag {
  padding: 5px 12px; border-radius: 20px;
  font-size: 13px; font-weight: 500;
  background: var(--bg-card); border: 1px solid var(--border);
  color: var(--text-secondary);
  transition: border-color var(--transition);
}
.skill-tag:hover { border-color: var(--border-hover); }

/* ===== Projects ===== */
.project-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px;
}

.project-card {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 24px;
  transition: all var(--transition);
}
.project-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.project-header {
  display: flex; align-items: flex-start; gap: 12px;
  margin-bottom: 12px;
}

.project-icon {
  width: 48px; height: 48px; flex-shrink: 0; border-radius: 12px;
  object-fit: cover;
}

.app-hero-icon {
  width: 80px; height: 80px; border-radius: 18px; margin-bottom: 12px;
  object-fit: cover;
}

.project-header h3 {
  font-size: 16px; font-weight: 600; margin-bottom: 2px;
}

.project-meta {
  font-size: 13px; color: var(--text-muted);
}

.project-card > p {
  font-size: 14px; color: var(--text-secondary); line-height: 1.6;
  margin-bottom: 16px;
}

.project-tech {
  display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 16px;
}
.project-tech span {
  padding: 3px 10px; border-radius: 14px;
  font-size: 12px; font-weight: 500;
  background: var(--accent-soft); color: var(--accent);
}

/* ===== Experience ===== */
.exp-group { margin-bottom: 40px; }
.exp-group:last-of-type { margin-bottom: 0; }

.exp-group-label {
  font-size: 12px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--accent); margin-bottom: 20px;
  padding-left: 28px;
}

.exp-item {
  display: flex; gap: 16px; padding-bottom: 28px;
  position: relative;
}
.exp-item:last-child { padding-bottom: 0; }

.exp-dot {
  width: 10px; height: 10px; flex-shrink: 0;
  border-radius: 50%; background: var(--border);
  border: 2px solid var(--bg);
  margin-top: 6px; position: relative; z-index: 1;
}

.exp-item:not(:last-child) .exp-dot::after {
  content: ''; position: absolute;
  top: 12px; left: 50%; transform: translateX(-50%);
  width: 1px; height: calc(100% + 22px);
  background: var(--border);
}

.exp-content { flex: 1; min-width: 0; }

.exp-top {
  display: flex; justify-content: space-between; align-items: baseline;
  gap: 12px; margin-bottom: 2px;
}

.exp-top h4 {
  font-size: 15px; font-weight: 600;
}

.exp-date {
  font-size: 13px; color: var(--text-muted); white-space: nowrap;
}

.exp-company {
  font-size: 13px; color: var(--text-muted); margin-bottom: 6px;
}
.exp-company a { color: var(--text-secondary); }
.exp-company a:hover { color: var(--accent); }

.exp-content > p:last-child {
  font-size: 14px; color: var(--text-secondary); line-height: 1.6;
}
.exp-content > p:last-child a { color: var(--text-secondary); text-decoration: underline; }
.exp-content > p:last-child a:hover { color: var(--accent); }

/* ===== Education ===== */
.edu-row {
  display: flex; gap: 16px; margin-top: 48px;
  padding-top: 32px; border-top: 1px solid var(--border);
}

.edu-card {
  flex: 1; padding: 20px; border-radius: var(--radius);
  background: var(--bg-card); border: 1px solid var(--border);
}
.edu-card h4 { font-size: 15px; font-weight: 600; margin-bottom: 4px; }
.edu-card p { font-size: 13px; color: var(--text-muted); }

.edu-card--highlight {
  border-color: var(--accent);
  background: linear-gradient(135deg, var(--bg-card), var(--accent-soft));
}

/* ===== Apps ===== */
.apps-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px;
}

.app-card {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 20px;
  transition: border-color var(--transition);
}
.app-card:hover { border-color: var(--border-hover); }

.app-card h3 {
  font-size: 15px; font-weight: 600; margin-bottom: 12px;
}

.app-links { display: flex; flex-wrap: wrap; gap: 12px; }
.app-links a {
  font-size: 13px; color: var(--text-secondary); font-weight: 500;
  transition: color var(--transition);
}
.app-links a:hover { color: var(--accent); opacity: 1; }

/* ===== Contact ===== */
.contact-wrap { text-align: center; max-width: 560px; }

.contact-text {
  font-size: 16px; color: var(--text-secondary); line-height: 1.7;
  margin-bottom: 28px;
}

/* ===== Footer ===== */
.footer {
  border-top: 1px solid var(--border); padding: 24px 0;
}

.footer-inner {
  display: flex; align-items: center; justify-content: space-between;
  font-size: 13px; color: var(--text-muted);
}

.footer-inner a { color: var(--text-muted); font-weight: 500; }
.footer-inner a:hover { color: var(--text); }

/* ===== Scroll Animations ===== */
.fade-up {
  opacity: 0; transform: translateY(24px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.fade-up.visible {
  opacity: 1; transform: translateY(0);
}

/* ===== Mobile ===== */
@media (max-width: 768px) {
  .container { padding: 0 20px; }

  .hero { padding: 48px 0 40px; }
  .hero-layout { flex-direction: column; gap: 24px; }
  .hero-text h1 { font-size: 26px; }
  .intro { max-width: 100%; }

  .about-grid { flex-direction: column; gap: 24px; }
  .stats { justify-content: flex-start; }

  .project-grid { grid-template-columns: 1fr; }
  .apps-grid { grid-template-columns: 1fr; }

  .exp-top { flex-direction: column; gap: 2px; }
  .edu-row { flex-direction: column; }

  .nav { display: none; }
  .nav.open {
    display: flex; flex-direction: column;
    position: absolute; top: 64px; left: 0; right: 0;
    background: var(--bg); border-bottom: 1px solid var(--border);
    padding: 8px 20px 16px;
  }
  .nav-toggle { display: flex; }

  .section { padding: 48px 0; }
}

@media (max-width: 480px) {
  .hero-text h1 { font-size: 22px; }
  .hero-photo img { width: 96px; height: 96px; border-radius: 20px; }
  .hero-actions { flex-direction: column; }
  .hero-actions .btn { width: 100%; }
  .section { padding: 40px 0; }
}

/* ===== Store Badges ===== */
.store-badge {
  display: inline-block;
  transition: transform var(--transition), opacity var(--transition);
}
.store-badge:hover { transform: scale(1.03); opacity: 1; }
.store-badge svg { display: block; border-radius: 6px; border: 1px solid var(--border); }
.store-badge--lg svg { border: none; }

/* ===== Project Actions ===== */
.project-actions {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
}

.btn--coming-soon {
  opacity: 0.5; cursor: default; pointer-events: none;
  border: 1px dashed var(--border);
}

.project-legal {
  display: flex; gap: 16px; margin-top: 12px;
  padding-top: 12px; border-top: 1px solid var(--border);
}
.project-legal a {
  font-size: 12px; color: var(--text-muted); font-weight: 500;
}
.project-legal a:hover { color: var(--text-secondary); }

/* ===== Experience Highlights ===== */
.exp-highlights {
  list-style: none; padding: 0; margin: 8px 0 0;
}
.exp-highlights li {
  position: relative; padding-left: 16px;
  font-size: 14px; color: var(--text-secondary);
  line-height: 1.6;
}
.exp-highlights li::before {
  content: ''; position: absolute; left: 0; top: 10px;
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent);
}
.exp-highlights li strong {
  color: var(--text-primary); font-weight: 600;
}

/* ===== Experience App Badges ===== */
.exp-apps {
  display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px;
}
.exp-app-badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 12px; border-radius: 8px;
  background: #000; color: #fff;
  font-size: 12px; font-weight: 500;
  border: 1px solid rgba(255,255,255,0.15);
  transition: border-color 0.2s, background 0.2s;
}
.exp-app-badge:hover {
  background: #1a1a1a; border-color: rgba(255,255,255,0.3);
  color: #fff;
}
.exp-app-badge svg { flex-shrink: 0; }

/* ===== Experience Tool Tags ===== */
.exp-tools {
  display: flex; flex-wrap: wrap; gap: 5px; margin-top: 8px;
}
.exp-tools span {
  padding: 2px 8px; border-radius: 12px;
  font-size: 11px; font-weight: 500;
  background: var(--accent-soft); color: var(--accent);
}

/* ===== App Hero (Showcase Pages) ===== */
.app-hero {
  padding: 80px 0 64px;
  border-bottom: 1px solid var(--border);
}

.app-hero-layout {
  display: flex; gap: 48px; align-items: center;
}

.app-hero-text { flex: 1; }

.app-label {
  font-size: 13px; font-weight: 500; color: var(--text-muted);
  text-transform: uppercase; letter-spacing: 0.05em;
  margin-bottom: 8px;
}

.app-hero-text h1 {
  font-size: 36px; font-weight: 800; letter-spacing: -0.03em;
  line-height: 1.1; margin-bottom: 12px;
}

.app-tagline {
  font-size: 18px; font-weight: 500; color: var(--text-secondary);
  margin-bottom: 16px;
}

.app-desc {
  font-size: 15px; color: var(--text-muted); line-height: 1.7;
  margin-bottom: 20px; max-width: 520px;
}

.app-rating {
  font-size: 14px; font-weight: 600; color: var(--green);
  margin-bottom: 20px;
}

.app-badges { margin-bottom: 20px; display: flex; gap: 12px; flex-wrap: wrap; }

.app-tech-row {
  display: flex; flex-wrap: wrap; gap: 6px;
}
.app-tech-row span {
  padding: 4px 10px; border-radius: 14px;
  font-size: 12px; font-weight: 500;
  background: var(--accent-soft); color: var(--accent);
}

.app-hero-image {
  flex-shrink: 0; max-width: 280px;
}
.app-hero-image img {
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.app-legal {
  display: flex; gap: 20px; justify-content: center; margin-top: 24px;
}
.app-legal a {
  font-size: 13px; color: var(--text-muted); font-weight: 500;
}
.app-legal a:hover { color: var(--text-secondary); }

/* ===== Showcase Gallery ===== */
.showcase-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px;
}

.showcase-item {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius); overflow: hidden;
  transition: all var(--transition);
}
.showcase-item:hover {
  border-color: var(--border-hover);
  transform: translateY(-3px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}

.showcase-item img {
  width: 100%; aspect-ratio: 9/16; object-fit: cover;
}

.showcase-caption {
  padding: 16px;
}
.showcase-caption h3 {
  font-size: 15px; font-weight: 600; margin-bottom: 4px;
}
.showcase-caption p {
  font-size: 13px; color: var(--text-muted); line-height: 1.5;
}

/* ===== Mobile - Showcase ===== */
@media (max-width: 768px) {
  .app-hero { padding: 48px 0 40px; }
  .app-hero-layout { flex-direction: column; gap: 32px; }
  .app-hero-text h1 { font-size: 28px; }
  .app-hero-image { max-width: 220px; align-self: center; }
  .showcase-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; }
}

@media (max-width: 480px) {
  .app-hero-text h1 { font-size: 24px; }
  .showcase-grid { grid-template-columns: 1fr; max-width: 320px; margin: 0 auto; }
  .app-hero-image { max-width: 180px; }
}

/* ===== Legal Pages ===== */
.legal-page {
  max-width: 720px; margin: 0 auto;
  padding: 80px 20px 64px;
}
.legal-page h1 {
  font-size: 32px; font-weight: 800; letter-spacing: -0.03em;
  margin-bottom: 8px;
}
.legal-page .legal-updated {
  font-size: 13px; color: var(--text-muted); margin-bottom: 32px;
}
.legal-page h2 {
  font-size: 18px; font-weight: 600; margin-top: 32px; margin-bottom: 12px;
  color: var(--text);
}
.legal-page p, .legal-page li {
  font-size: 15px; color: var(--text-secondary); line-height: 1.7;
  margin-bottom: 12px;
}
.legal-page ul {
  padding-left: 20px; margin-bottom: 16px;
}
.legal-page li { margin-bottom: 8px; }
.legal-page a { color: var(--accent); }
.legal-page a:hover { text-decoration: underline; }

.legal-contact {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 24px;
  margin-top: 40px;
}
.legal-contact h2 { margin-top: 0; }
.legal-contact p { margin-bottom: 6px; }

/* Support page */
.support-page {
  max-width: 720px; margin: 0 auto;
  padding: 80px 20px 64px; text-align: center;
}
.support-page h1 {
  font-size: 32px; font-weight: 800; letter-spacing: -0.03em;
  margin-bottom: 12px;
}
.support-page > p {
  font-size: 16px; color: var(--text-secondary); margin-bottom: 32px;
}
.support-contact-box {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 32px;
  display: inline-block;
}
.support-contact-box p {
  font-size: 15px; color: var(--text-secondary); margin-bottom: 16px;
}
.support-btn {
  display: inline-block; padding: 12px 28px; border-radius: var(--radius-sm);
  background: var(--accent); color: #fff; font-weight: 600; font-size: 15px;
  text-decoration: none; transition: background var(--transition);
}
.support-btn:hover { background: #2563eb; }
.support-links {
  margin-top: 32px; display: flex; gap: 20px; justify-content: center;
}
.support-links a {
  font-size: 13px; color: var(--text-muted); font-weight: 500;
}
.support-links a:hover { color: var(--text-secondary); }
.faq-section {
  text-align: left; margin-top: 48px;
}
.faq-section h2 {
  font-size: 20px; font-weight: 700; text-align: center;
  margin-bottom: 24px;
}
.faq-item { margin-bottom: 20px; }
.faq-item h3 {
  font-size: 15px; font-weight: 600; color: var(--text); margin-bottom: 4px;
}
.faq-item p {
  font-size: 14px; color: var(--text-secondary); line-height: 1.6; margin: 0;
}

@media (max-width: 768px) {
  .legal-page { padding: 64px 20px 48px; }
  .legal-page h1 { font-size: 26px; }
  .support-page { padding: 64px 20px 48px; }
  .support-page h1 { font-size: 26px; }
}

/* ===== Focus ===== */
a:focus-visible, button:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 2px;
}
