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

:root {
  --primary: #2E7D32;
  --primary-dark: #1B5E20;
  --text: #333;
  --text-light: #666;
  --bg: #fff;
  --bg-alt: #f8f9fa;
  --max-width: 1100px;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
  color: var(--text);
  line-height: 1.6;
}

/* Hero */
.hero {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: white;
  padding: 80px 24px;
  text-align: center;
}

.hero h1 {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 16px;
  line-height: 1.2;
}

.hero p {
  font-size: 1.1rem;
  opacity: 0.9;
  max-width: 600px;
  margin: 0 auto 32px;
}

.hero .cta {
  display: inline-block;
  background: white;
  color: var(--primary);
  padding: 14px 32px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  transition: transform 0.2s, box-shadow 0.2s;
}

.hero .cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.hero-ctas {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

.hero .cta.cta-secondary {
  background: transparent;
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.5);
}

.hero .cta.cta-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
  box-shadow: none;
}

/* Feature sections */
.feature {
  display: flex;
  gap: 48px;
  padding: 64px 24px;
  max-width: var(--max-width);
  margin: 0 auto;
  align-items: center;
}

.feature:nth-child(even) {
  flex-direction: row-reverse;
}

.feature-text {
  flex: 1;
}

.feature-tag {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--primary);
  font-weight: 600;
  margin-bottom: 8px;
}

.feature-text h2 {
  font-size: 1.5rem;
  margin-bottom: 12px;
  line-height: 1.3;
}

.feature-text p {
  color: var(--text-light);
  font-size: 1rem;
}

.feature-image {
  flex: 1;
}

.feature-image img {
  width: 100%;
  border-radius: 12px;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.1);
}

.feature-image-mobile {
  display: flex;
  gap: 16px;
  justify-content: center;
}

.feature-image-mobile img {
  width: auto;
  max-width: calc(50% - 8px);
  max-height: 540px;
  border-radius: 24px;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.12);
}

/* Divider between features */
.features-container .feature + .feature {
  border-top: 1px solid #eee;
}

/* Footer */
.footer {
  background: var(--bg-alt);
  padding: 48px 24px;
  text-align: center;
}

.footer h2 {
  font-size: 1.3rem;
  margin-bottom: 16px;
  color: var(--text);
}

.footer-links {
  display: flex;
  gap: 24px;
  justify-content: center;
  margin-top: 16px;
}

.footer-links a {
  color: var(--text-light);
  text-decoration: none;
  font-size: 0.9rem;
}

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

/* Lightbox */
.lightbox {
  border: none;
  background: none;
  padding: 0;
  max-width: 90vw;
  max-height: 90vh;
}

.lightbox::backdrop {
  background: rgba(0, 0, 0, 0.8);
}

.lightbox img {
  max-width: 90vw;
  max-height: 85vh;
  border-radius: 12px;
  display: block;
}

.lightbox-close {
  position: absolute;
  top: -12px;
  right: -12px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: white;
  color: var(--text);
  font-size: 1.3rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.lightbox-close:hover {
  background: #eee;
}

/* Demo-Page */
.demo-body {
  margin: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.demo-banner {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: white;
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.demo-banner-text {
  font-size: 0.95rem;
}

.demo-banner-back {
  color: white;
  text-decoration: none;
  margin-left: 16px;
  opacity: 0.85;
  font-size: 0.9rem;
}

.demo-banner-back:hover {
  opacity: 1;
}

.demo-banner-btn {
  background: white;
  color: var(--primary);
  border: none;
  padding: 8px 20px;
  border-radius: 6px;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s;
}

.demo-banner-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.demo-iframe {
  flex: 1;
  width: 100%;
  border: none;
  display: block;
}

/* Credentials modal */
.credentials {
  border: none;
  border-radius: 12px;
  padding: 0;
  max-width: 520px;
  width: 90vw;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
}

.credentials::backdrop {
  background: rgba(0, 0, 0, 0.6);
}

.credentials-content {
  padding: 32px;
  position: relative;
}

.credentials-content h2 {
  font-size: 1.3rem;
  margin-bottom: 8px;
}

.credentials-hint {
  color: var(--text-light);
  font-size: 0.9rem;
  margin-bottom: 20px;
}

.credentials-hint code {
  background: var(--bg-alt);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.85rem;
}

.credentials-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: none;
  background: var(--bg-alt);
  color: var(--text);
  font-size: 1.2rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.credentials-close:hover {
  background: #e5e7eb;
}

.credentials-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
  margin-bottom: 16px;
}

.credentials-table th {
  text-align: left;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-light);
  padding: 8px 8px 8px 0;
  border-bottom: 1px solid #eee;
}

.credentials-table td {
  padding: 10px 8px 10px 0;
  border-bottom: 1px solid #f3f4f6;
}

.credentials-table code {
  font-size: 0.85rem;
  color: var(--text);
}

.copy-btn {
  background: var(--primary);
  color: white;
  border: none;
  padding: 6px 14px;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s;
}

.copy-btn:hover {
  background: var(--primary-dark);
}

.copy-btn-done {
  background: #10b981 !important;
}

.copy-btn-wide {
  display: block;
  width: 100%;
  padding: 10px;
  font-size: 0.9rem;
}

/* Sub-page hero (compact) */
.subpage-hero {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: white;
  padding: 56px 24px 40px;
}

.subpage-hero-inner {
  max-width: var(--max-width);
  margin: 0 auto;
}

.subpage-hero a.back {
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.9rem;
  text-decoration: none;
  display: inline-block;
  margin-bottom: 24px;
}

.subpage-hero a.back:hover {
  color: white;
}

.subpage-tag {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  opacity: 0.85;
  margin-bottom: 8px;
  font-weight: 600;
}

.subpage-hero h1 {
  font-size: 2.2rem;
  font-weight: 700;
  line-height: 1.15;
  max-width: 720px;
  margin-bottom: 16px;
}

.subpage-hero .lede {
  font-size: 1.1rem;
  opacity: 0.9;
  max-width: 640px;
}

/* Sub-page sections */
.section {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 64px 24px;
}

.section-narrow {
  max-width: 760px;
}

.section h2 {
  font-size: 1.6rem;
  margin-bottom: 16px;
  line-height: 1.3;
}

.section p {
  color: var(--text-light);
  margin-bottom: 12px;
}

.section .lead {
  font-size: 1.1rem;
  color: var(--text);
  margin-bottom: 24px;
}

.section + .section {
  border-top: 1px solid #eee;
}

.section.alt {
  background: var(--bg-alt);
  max-width: none;
  padding-left: 24px;
  padding-right: 24px;
}

.section.alt > .section-inner {
  max-width: var(--max-width);
  margin: 0 auto;
}

.section.alt.narrow > .section-inner {
  max-width: 760px;
}

/* Numbered steps */
.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 24px;
  margin-top: 24px;
}

.step {
  background: white;
  border-radius: 12px;
  padding: 24px;
  border: 1px solid #eee;
}

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--primary);
  color: white;
  font-weight: 700;
  font-size: 0.95rem;
  margin-bottom: 12px;
}

.step h3 {
  font-size: 1.05rem;
  margin-bottom: 8px;
}

.step p {
  font-size: 0.95rem;
  margin: 0;
}

/* Detail screenshot */
.detail-shot {
  margin-top: 32px;
}

.detail-shot img {
  width: 100%;
  border-radius: 12px;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.1);
  display: block;
}

.detail-shot figcaption {
  margin-top: 12px;
  text-align: center;
  font-size: 0.9rem;
  color: var(--text-light);
}

/* Use-case pills */
.use-cases {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 16px;
}

.use-case {
  background: white;
  border: 1px solid #ddd;
  padding: 8px 16px;
  border-radius: 999px;
  font-size: 0.9rem;
  color: var(--text);
}

/* FAQ */
.faq {
  margin-top: 24px;
}

.faq details {
  background: white;
  border: 1px solid #eee;
  border-radius: 8px;
  padding: 16px 20px;
  margin-bottom: 12px;
}

.faq details[open] {
  border-color: var(--primary);
}

.faq summary {
  cursor: pointer;
  font-weight: 600;
  list-style: none;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: '+';
  float: right;
  font-size: 1.2rem;
  color: var(--text-light);
  transition: transform 0.15s;
}

.faq details[open] summary::after {
  transform: rotate(45deg);
}

.faq details > p {
  margin-top: 12px;
  color: var(--text-light);
}

/* Bottom CTA */
.cta-block {
  background: var(--bg-alt);
  padding: 56px 24px;
  text-align: center;
}

.cta-block h2 {
  font-size: 1.4rem;
  margin-bottom: 20px;
}

.cta-block .cta {
  display: inline-block;
  background: var(--primary);
  color: white;
  padding: 14px 32px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  margin: 0 6px;
}

.cta-block .cta:hover {
  background: var(--primary-dark);
}

.cta-block .cta.cta-secondary {
  background: transparent;
  color: var(--primary);
  border: 2px solid var(--primary);
}

.cta-block .cta.cta-secondary:hover {
  background: var(--primary);
  color: white;
}

/* Feature card link variant on landing */
.feature-link {
  display: inline-block;
  margin-top: 12px;
  color: var(--primary);
  font-weight: 600;
  text-decoration: none;
  font-size: 0.95rem;
}

.feature-link::after {
  content: ' →';
}

.feature-link:hover {
  text-decoration: underline;
}

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

  .feature,
  .feature:nth-child(even) {
    flex-direction: column;
    gap: 24px;
    padding: 40px 24px;
  }

  .demo-banner {
    padding: 10px 16px;
    font-size: 0.85rem;
  }

  .demo-banner-back {
    display: block;
    margin: 4px 0 0;
  }

  .subpage-hero {
    padding: 40px 24px 32px;
  }

  .subpage-hero h1 {
    font-size: 1.6rem;
  }

  .section {
    padding: 40px 24px;
  }
}
