/* =============================================
   Episode Lock – Global Stylesheet
   ============================================= */

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: #1a1a2e;
  background: #f8f9ff;
}

/* ----- Layout ----- */
.container {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ----- Typography ----- */
h1, h2, h3 {
  line-height: 1.2;
  font-weight: 700;
}

h1 { font-size: clamp(2rem, 5vw, 3.2rem); }
h2 { font-size: clamp(1.4rem, 3vw, 2rem); margin-bottom: 1rem; }
h3 { font-size: 1.1rem; margin-bottom: 0.4rem; }

a {
  color: #4f46e5;
  text-decoration: none;
}
a:hover { text-decoration: underline; }

/* ----- Header ----- */
.site-header {
  background: #fff;
  border-bottom: 1px solid #e2e8f0;
  position: sticky;
  top: 0;
  z-index: 100;
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 1rem;
  padding-bottom: 1rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.2rem;
  font-weight: 700;
  color: #1a1a2e;
}

.logo-icon-image {
  width: 2rem;
  height: 2rem;
  border-radius: 0.45rem;
  box-shadow: 0 2px 6px rgba(26, 26, 46, 0.2);
}

nav {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

nav a {
  color: #4a5568;
  font-weight: 500;
  font-size: 0.95rem;
}
nav a:hover { color: #4f46e5; text-decoration: none; }

/* ----- Locale Switcher ----- */
.locale-switcher {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.85rem;
  font-weight: 600;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  padding: 0.2rem 0.65rem;
  color: #4a5568;
  margin-left: 0.5rem;
}

.locale-switcher .locale-link {
  color: #4a5568;
  text-decoration: none;
  padding: 0.1rem 0.15rem;
}

.locale-switcher .locale-link:hover {
  color: #4f46e5;
}

.locale-switcher .locale-link.active {
  color: #4f46e5;
  font-weight: 700;
}

.locale-switcher .locale-sep {
  color: #cbd5e0;
  user-select: none;
}

/* ----- Hero ----- */
.hero {
  background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
  color: #fff;
  padding: 5rem 0;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 2rem;
}

.hero h1 {
  margin-bottom: 1.2rem;
  max-width: 14ch;
}

.hero-subtitle {
  font-size: 1.15rem;
  opacity: 0.9;
  max-width: 520px;
  margin-bottom: 1.5rem;
}

.hero-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.hero-note {
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.86);
  margin-top: 0.55rem;
}

.hero-note-main {
  font-weight: 500;
}

.hero-note-support {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin-top: 0.35rem;
  padding: 0.28rem 0.7rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  background: rgba(15, 23, 42, 0.18);
  color: rgba(255, 255, 255, 0.94);
}

.hero-note-icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  display: block;
}

.hero-media {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.9rem;
}

.hero-shot {
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.32);
  box-shadow: 0 18px 36px rgba(15, 23, 42, 0.28);
  background: rgba(255, 255, 255, 0.08);
}

.hero-shot img {
  width: 100%;
  height: auto;
  display: block;
}

.hero-shot figcaption {
  padding: 0.5rem 0.75rem;
  font-size: 0.82rem;
  letter-spacing: 0.01em;
  color: rgba(255, 255, 255, 0.92);
}

/* ----- Buttons ----- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.75rem;
  border-radius: 8px;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: opacity 0.2s, transform 0.1s;
  text-decoration: none;
}
.btn:hover { opacity: 0.9; transform: translateY(-1px); text-decoration: none; }
.btn:active { transform: translateY(0); }

.btn-primary {
  background: #fff;
  color: #4f46e5;
}

.btn-ghost {
  color: #f8f9ff;
  border: 1px solid rgba(255, 255, 255, 0.75);
  background: rgba(26, 26, 46, 0.24);
}

.btn-ghost:hover {
  background: rgba(26, 26, 46, 0.34);
}

.btn-browser {
  background: #fff;
  color: #1a1a2e;
  border: 1px solid #e2e8f0;
  box-shadow: 0 1px 4px rgba(0,0,0,0.07);
}
.btn-browser:hover { background: #f8f9ff; }

/* ----- Features ----- */
.features {
  padding: 4rem 0;
  background: #fff;
}

.features h2 {
  text-align: center;
  margin-bottom: 2.5rem;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 1.5rem;
}

.feature-card {
  background: #f8f9ff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 1.5rem;
}

.feature-icon {
  font-size: 2rem;
  margin-bottom: 0.75rem;
}

.feature-card p {
  color: #4a5568;
  font-size: 0.95rem;
}

.feature-card table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 0.5rem;
  font-size: 0.9rem;
}

.feature-card th,
.feature-card td {
  border: 1px solid #dbe1ec;
  padding: 0.45rem 0.55rem;
  text-align: left;
  vertical-align: top;
}

.feature-card th {
  background: #edf2ff;
  color: #2d3748;
}

.feature-card ul,
.feature-card ol {
  padding-left: 1.2rem;
  margin-top: 0.4rem;
}

.feature-card li {
  color: #4a5568;
  font-size: 0.95rem;
  margin-bottom: 0.25rem;
}

/* ----- Screenshot Showcase ----- */
.showcase {
  padding: 4rem 0;
  background: linear-gradient(180deg, #eef2ff 0%, #f8f9ff 100%);
}

.showcase h2,
.showcase-subtitle {
  text-align: center;
}

.showcase-subtitle {
  color: #4a5568;
  margin: 0 auto 2rem;
  max-width: 680px;
}

.showcase-grid {
  display: grid;
  gap: 1.25rem;
}

.showcase-card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 14px 26px rgba(79, 70, 229, 0.09);
}

.showcase-card img {
  width: 100%;
  height: auto;
  display: block;
}

.showcase-copy {
  padding: 1rem 1.1rem 1.2rem;
}

.showcase-copy p {
  color: #4a5568;
  margin: 0;
}

/* ----- Install ----- */
.install {
  padding: 4rem 0;
  text-align: center;
}

.install h2 { margin-bottom: 0.5rem; }
.install > .container > p { color: #4a5568; margin-bottom: 1.5rem; }

.install-buttons {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.note {
  font-size: 0.85rem;
  color: #718096;
}

.install > .container > p.install-support-note {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin: -0.25rem auto 1.25rem;
  padding: 0.5rem 0.95rem;
  border-radius: 999px;
  border: 1px solid #cfd6e6;
  background: #eef2ff;
  color: #475569;
  font-size: 0.92rem;
  font-weight: 600;
  line-height: 1.2;
}

.install-support-note img {
  display: block;
  width: 18px;
  height: 18px;
}

/* ----- How It Works ----- */
.how-it-works {
  padding: 4rem 0;
  background: #fff;
}

.how-it-works h2 {
  text-align: center;
  margin-bottom: 2.5rem;
}

.steps {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  max-width: 680px;
  margin: 0 auto;
}

.steps li {
  display: flex;
  align-items: flex-start;
  gap: 1.25rem;
}

.step-number {
  flex-shrink: 0;
  width: 2.25rem;
  height: 2.25rem;
  background: #4f46e5;
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1rem;
}

.steps p { color: #4a5568; font-size: 0.95rem; }

pre {
  background: #f3f5ff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 0.9rem;
  overflow-x: auto;
  font-size: 0.86rem;
  line-height: 1.45;
  color: #1f2937;
  white-space: pre;
}

/* ----- Footer ----- */
.site-footer {
  background: #1a1a2e;
  color: #a0aec0;
  padding: 2rem 0;
  text-align: center;
  font-size: 0.9rem;
}

.site-footer a {
  color: #90cdf4;
}
.site-footer a:hover { color: #fff; }

/* ----- Privacy & Support pages ----- */
.page-content {
  padding: 3rem 0 5rem;
  max-width: 720px;
  margin: 0 auto;
}

.page-content h1 {
  margin-bottom: 0.5rem;
}

.page-content .subtitle {
  color: #718096;
  margin-bottom: 2rem;
  font-size: 0.95rem;
}

.page-content h2 {
  margin-top: 2rem;
  margin-bottom: 0.6rem;
  font-size: 1.2rem;
}

.page-content p,
.page-content li {
  color: #4a5568;
  margin-bottom: 0.75rem;
}

.page-content ul,
.page-content ol {
  padding-left: 1.4rem;
}

.page-content a { font-weight: 500; }

/* ----- FAQ / Accordion (support page) ----- */
.faq-list {
  list-style: none;
  padding: 0;
  margin-top: 1rem;
}

.faq-item {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  margin-bottom: 0.75rem;
  overflow: hidden;
}

.faq-question {
  width: 100%;
  background: #fff;
  border: none;
  padding: 1rem 1.25rem;
  text-align: left;
  font-size: 1rem;
  font-weight: 600;
  color: #1a1a2e;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.faq-question:hover { background: #f8f9ff; }

.faq-answer {
  display: none;
  padding: 0 1.25rem 1rem;
  color: #4a5568;
  font-size: 0.95rem;
}

.faq-item.open .faq-answer { display: block; }
.faq-item.open .faq-chevron { transform: rotate(180deg); }

.faq-chevron {
  transition: transform 0.2s;
  font-style: normal;
}

/* ----- Blog / Story page ----- */
.blog-post {
  padding: 3rem 0 5rem;
}

.blog-header {
  max-width: 720px;
  margin: 0 auto 2rem;
  text-align: center;
}

.blog-meta {
  font-size: 0.85rem;
  font-weight: 600;
  color: #4f46e5;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.75rem;
}

.blog-header h1 {
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  margin-bottom: 0.75rem;
  color: #1a1a2e;
}

.blog-byline {
  font-size: 0.9rem;
  color: #718096;
}

.blog-hero-image {
  max-width: 820px;
  margin: 0 auto 2.5rem;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 18px 40px rgba(79, 70, 229, 0.12);
}

.blog-hero-image img {
  width: 100%;
  height: auto;
  display: block;
}

.blog-hero-image figcaption {
  font-size: 0.78rem;
  color: #a0aec0;
  text-align: right;
  padding: 0.4rem 0.75rem;
  background: #f8f9ff;
}

.blog-hero-image figcaption a {
  color: #a0aec0;
}

.blog-body {
  max-width: 680px;
  margin: 0 auto;
  font-size: 1.05rem;
  line-height: 1.75;
  color: #2d3748;
}

.blog-body p {
  margin-bottom: 1.25rem;
}

.blog-body h2 {
  font-size: 1.3rem;
  color: #1a1a2e;
  margin-top: 2.5rem;
  margin-bottom: 0.75rem;
  border-left: 4px solid #4f46e5;
  padding-left: 0.75rem;
}

.blog-body em {
  color: #4f46e5;
  font-style: italic;
}

.blog-cta {
  max-width: 680px;
  margin: 3rem auto 0;
  padding: 2rem;
  background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
  border-radius: 16px;
  text-align: center;
  color: #fff;
}

.blog-cta p {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 1.25rem;
}

.blog-cta .btn-primary {
  background: #fff;
  color: #4f46e5;
  font-size: 1rem;
}

.blog-cta-back {
  display: block;
  margin-top: 1rem;
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.8);
}

.blog-cta-back:hover {
  color: #fff;
  text-decoration: none;
}

/* ----- Story Teaser (homepage section) ----- */
.story-teaser {
  padding: 4rem 0;
  background: linear-gradient(180deg, #f0edff 0%, #f8f9ff 100%);
}

.story-teaser h2 {
  text-align: center;
  margin-bottom: 0.5rem;
}

.story-teaser-subtitle {
  text-align: center;
  color: #4a5568;
  margin-bottom: 2rem;
  font-size: 0.95rem;
}

.story-card {
  max-width: 760px;
  margin: 0 auto;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 12px 28px rgba(79, 70, 229, 0.1);
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.story-card-image {
  overflow: hidden;
}

.story-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.story-card:hover .story-card-image img {
  transform: scale(1.03);
}

.story-card-body {
  padding: 2rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.story-card-label {
  font-size: 0.78rem;
  font-weight: 700;
  color: #4f46e5;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.6rem;
}

.story-card-body h3 {
  font-size: 1.15rem;
  color: #1a1a2e;
  margin-bottom: 0.75rem;
  line-height: 1.35;
}

.story-card-body p {
  font-size: 0.93rem;
  color: #4a5568;
  line-height: 1.65;
  margin-bottom: 1.25rem;
}

.story-read-more {
  font-size: 0.93rem;
  font-weight: 600;
  color: #4f46e5;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}

.story-read-more:hover {
  text-decoration: underline;
}

/* ----- Responsive ----- */
@media (max-width: 600px) {
  .site-header .container {
    flex-direction: column;
    gap: 0.75rem;
    text-align: center;
  }

  .hero-grid {
    grid-template-columns: 1fr;
    gap: 1.2rem;
  }

  .hero-copy {
    text-align: center;
  }

  .hero h1,
  .hero-subtitle {
    margin-left: auto;
    margin-right: auto;
  }

  .hero-actions {
    justify-content: center;
  }

  .hero { padding: 3.5rem 0; }

  .story-card {
    grid-template-columns: 1fr;
  }

  .story-card-image {
    height: 200px;
  }
}
