/* ==========================================================================
   Artalk Website - Static Site Styles
   Theme matches the mobile app's dark indigo/purple palette
   ========================================================================== */

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

:root {
  --primary: #6366f1;
  --primary-shade: #575ad4;
  --primary-tint: #7376f2;
  --secondary: #818cf8;
  --tertiary: #a855f7;
  --accent: #a5b4fc;
  --gradient-start: #6366f1;
  --gradient-end: #a855f7;
  --bg-dark: #0f172a;
  --bg-card: rgba(255, 255, 255, 0.05);
  --bg-card-hover: rgba(255, 255, 255, 0.08);
  --text-primary: #f1f5f9;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --success: #10b981;
  --warning: #f59e0b;
  --danger: #ef4444;
  --border: rgba(255, 255, 255, 0.1);
  --font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --max-width: 1100px;
  --radius: 12px;
  --radius-sm: 8px;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-family);
  background-color: var(--bg-dark);
  color: var(--text-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

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

a:hover {
  color: var(--secondary);
}

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

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

main {
  flex: 1;
}

/* --- Header / Nav --- */
.site-header {
  background: rgba(15, 23, 42, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}

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

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  font-weight: 700;
  color: var(--text-primary);
  text-decoration: none;
}

.logo img {
  width: 36px;
  height: 36px;
  border-radius: 8px;
}

.logo span {
  background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

nav {
  display: flex;
  align-items: center;
  gap: 28px;
}

nav a {
  color: var(--text-secondary);
  font-size: 15px;
  font-weight: 500;
  transition: color 0.2s;
}

nav a:hover,
nav a.active {
  color: var(--text-primary);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 24px;
  cursor: pointer;
  padding: 4px;
}

/* --- Hero Section --- */
.hero {
  padding: 80px 0 60px;
  text-align: center;
}

.hero h1 {
  font-size: 48px;
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 20px;
  background: linear-gradient(135deg, var(--text-primary), var(--accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero .subtitle {
  font-size: 20px;
  color: var(--text-secondary);
  max-width: 640px;
  margin: 0 auto 36px;
  line-height: 1.5;
}

.hero-badge {
  display: inline-block;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 6px 16px;
  font-size: 13px;
  color: var(--accent);
  margin-bottom: 24px;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  border-radius: var(--radius-sm);
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  border: none;
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
  color: #fff;
}

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

.btn-outline {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-primary);
}

.btn-outline:hover {
  background: var(--bg-card);
  color: var(--text-primary);
}

.btn-group {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

/* --- Features Grid --- */
.features {
  padding: 60px 0;
}

.features h2 {
  text-align: center;
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 40px;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  transition: background 0.2s;
}

.feature-card:hover {
  background: var(--bg-card-hover);
}

.feature-icon {
  font-size: 28px;
  margin-bottom: 14px;
}

.feature-card h3 {
  font-size: 17px;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text-primary);
}

.feature-card p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* --- Tech Stack Section --- */
.tech-stack {
  padding: 60px 0;
}

.tech-stack h2 {
  text-align: center;
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 40px;
}

.tech-pills {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}

.tech-pill {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 8px 18px;
  font-size: 14px;
  color: var(--text-secondary);
}

/* --- Legal Pages (Privacy, Terms) --- */
.legal-page {
  padding: 60px 0;
}

.legal-page h1 {
  font-size: 36px;
  font-weight: 700;
  margin-bottom: 8px;
}

.legal-meta {
  color: var(--text-muted);
  font-size: 14px;
  margin-bottom: 36px;
}

.legal-content {
  max-width: 800px;
}

.legal-content h2 {
  color: var(--primary);
  font-size: 20px;
  font-weight: 600;
  margin-top: 32px;
  margin-bottom: 12px;
}

.legal-content h3 {
  color: var(--tertiary);
  font-size: 17px;
  font-weight: 600;
  margin-top: 20px;
  margin-bottom: 8px;
}

.legal-content p {
  color: var(--text-secondary);
  margin-bottom: 14px;
}

.legal-content ul {
  margin-left: 24px;
  margin-bottom: 14px;
  color: var(--text-secondary);
}

.legal-content li {
  margin-bottom: 8px;
}

/* --- Contact Page --- */
.contact-page {
  padding: 60px 0;
}

.contact-page h1 {
  font-size: 36px;
  font-weight: 700;
  margin-bottom: 8px;
}

.contact-page .subtitle {
  color: var(--text-secondary);
  margin-bottom: 40px;
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  max-width: 800px;
}

.contact-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
}

.contact-card .icon {
  font-size: 28px;
  margin-bottom: 14px;
}

.contact-card h3 {
  font-size: 17px;
  font-weight: 600;
  margin-bottom: 8px;
}

.contact-card p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* --- 404 Page --- */
.page-404 {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 120px 24px;
  flex: 1;
}

.page-404 .code {
  font-size: 120px;
  font-weight: 800;
  background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
  margin-bottom: 16px;
}

.page-404 h1 {
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 12px;
}

.page-404 p {
  color: var(--text-secondary);
  margin-bottom: 32px;
  font-size: 16px;
}

/* --- Footer --- */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 32px 0;
  margin-top: auto;
}

.site-footer .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-copy {
  font-size: 14px;
  color: var(--text-muted);
}

.footer-links {
  display: flex;
  gap: 20px;
}

.footer-links a {
  font-size: 14px;
  color: var(--text-secondary);
}

.footer-links a:hover {
  color: var(--text-primary);
}

/* --- Responsive --- */
@media (max-width: 768px) {
  .hero h1 {
    font-size: 32px;
  }

  .hero .subtitle {
    font-size: 17px;
  }

  .features h2,
  .tech-stack h2 {
    font-size: 26px;
  }

  .legal-page h1,
  .contact-page h1 {
    font-size: 28px;
  }

  .site-header .container {
    height: 56px;
  }

  nav {
    display: none;
    position: absolute;
    top: 56px;
    left: 0;
    right: 0;
    background: rgba(15, 23, 42, 0.98);
    backdrop-filter: blur(12px);
    flex-direction: column;
    padding: 16px 24px;
    gap: 16px;
    border-bottom: 1px solid var(--border);
  }

  nav.open {
    display: flex;
  }

  .nav-toggle {
    display: block;
  }
}

@media (max-width: 480px) {
  .hero {
    padding: 48px 0 40px;
  }

  .hero h1 {
    font-size: 28px;
  }

  .features,
  .tech-stack,
  .legal-page,
  .contact-page {
    padding: 40px 0;
  }
}
