/* ============================================================
   shelldone Landing Page — style.css
   Dark terminal-green aesthetic, responsive, zero dependencies
   ============================================================ */

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

:root {
  --green: #00ff41;
  --green-dim: #00cc33;
  --green-glow: rgba(0, 255, 65, 0.15);
  --green-glow-strong: rgba(0, 255, 65, 0.3);
  --bg: #0a0a0a;
  --bg-card: #111111;
  --bg-code: #0d0d0d;
  --bg-elevated: #161616;
  --border: #1e1e1e;
  --border-light: #2a2a2a;
  --text: #e0e0e0;
  --text-dim: #888888;
  --text-bright: #ffffff;
  --font-mono: "SF Mono", "Cascadia Code", "Fira Code", "JetBrains Mono", "Consolas", "Liberation Mono", "Menlo", monospace;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Helvetica Neue", Arial, sans-serif;
  --max-width: 1120px;
  --radius: 8px;
  --radius-lg: 12px;
  --transition: 0.25s ease;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: var(--green);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover {
  color: var(--text-bright);
}

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

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

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Skip-nav link — visible only on focus */
.skip-nav {
  position: absolute;
  top: -100%;
  left: 16px;
  z-index: 200;
  padding: 8px 16px;
  background: var(--green);
  color: var(--bg);
  font-weight: 600;
  font-size: 0.9rem;
  border-radius: var(--radius);
  transition: top 0.2s ease;
}

.skip-nav:focus {
  top: 8px;
  color: var(--bg);
}

/* --- Fade-in on scroll --- */
.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* --- Navigation --- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(10, 10, 10, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  padding: 0 24px;
}

.nav__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
}

.nav__logo {
  font-family: var(--font-mono);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--green);
  letter-spacing: -0.5px;
}

.nav__logo span {
  color: var(--text-dim);
  font-weight: 400;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 28px;
  list-style: none;
}

.nav__links a {
  color: var(--text-dim);
  font-size: 0.9rem;
  transition: color var(--transition);
}

.nav__links a:hover {
  color: var(--green);
}

.nav__github {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text-dim);
  font-size: 0.9rem;
}

.nav__github svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.nav__github:hover {
  color: var(--green);
}

/* Mobile nav toggle */
.nav__toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav__toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  margin: 5px 0;
  transition: var(--transition);
}

/* --- Hero --- */
.hero {
  padding: 160px 0 100px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  top: -200px;
  left: 50%;
  transform: translateX(-50%);
  width: 800px;
  height: 800px;
  background: radial-gradient(circle, var(--green-glow) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

.hero__content {
  position: relative;
  z-index: 1;
}

.hero__title {
  font-family: var(--font-mono);
  font-size: clamp(3rem, 8vw, 5.5rem);
  font-weight: 800;
  color: var(--green);
  letter-spacing: -2px;
  line-height: 1.1;
  margin-bottom: 16px;
  text-shadow: 0 0 40px var(--green-glow-strong);
}

.hero__tagline {
  font-size: clamp(1.2rem, 3vw, 1.6rem);
  color: var(--text-bright);
  font-weight: 600;
  margin-bottom: 12px;
}

.hero__subtitle {
  font-size: clamp(0.95rem, 2vw, 1.1rem);
  color: var(--text-dim);
  max-width: 680px;
  margin: 0 auto 40px;
  line-height: 1.7;
}

.hero__buttons {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 60px;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: var(--radius);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  border: none;
  font-family: var(--font-sans);
}

.btn--primary {
  background: var(--green);
  color: var(--bg);
}

.btn--primary:hover {
  background: var(--text-bright);
  color: var(--bg);
  box-shadow: 0 0 24px var(--green-glow-strong);
}

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

.btn--secondary:hover {
  border-color: var(--green);
  color: var(--green);
}

.btn svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

/* --- Terminal Animation --- */
.terminal {
  max-width: 600px;
  margin: 0 auto;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border-light);
  background: var(--bg-code);
  text-align: left;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.terminal__header {
  display: flex;
  align-items: center;
  padding: 12px 16px;
  background: var(--bg-elevated);
  border-bottom: 1px solid var(--border);
  gap: 8px;
}

.terminal__dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.terminal__dot--red { background: #ff5f57; }
.terminal__dot--yellow { background: #febc2e; }
.terminal__dot--green { background: #28c840; }

.terminal__title {
  flex: 1;
  text-align: center;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-dim);
}

.terminal__gif {
  width: 100%;
  display: block;
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
}

.terminal__body {
  padding: 20px;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  line-height: 1.8;
  min-height: 180px;
}

.terminal__line {
  white-space: nowrap;
  overflow: hidden;
}

.terminal__prompt {
  color: var(--green);
}

.terminal__command {
  color: var(--text-bright);
}

.terminal__output {
  color: var(--text-dim);
}


/* --- Section --- */
.section {
  padding: 100px 0;
}

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

.section__header {
  text-align: center;
  margin-bottom: 56px;
}

.section__label {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--green);
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 12px;
}

.section__title {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 700;
  color: var(--text-bright);
  margin-bottom: 12px;
}

.section__subtitle {
  font-size: 1.05rem;
  color: var(--text-dim);
  max-width: 600px;
  margin: 0 auto;
}

/* --- Feature Cards --- */
.features__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.feature-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px 28px;
  transition: all var(--transition);
}

.feature-card:hover {
  border-color: var(--green-dim);
  box-shadow: 0 0 30px var(--green-glow);
  transform: translateY(-4px);
}

.feature-card__icon {
  font-size: 1.8rem;
  margin-bottom: 16px;
  display: block;
  width: 48px;
  height: 48px;
  line-height: 48px;
  text-align: center;
  background: var(--green-glow);
  border-radius: var(--radius);
  color: var(--green);
  font-family: var(--font-mono);
  font-weight: 700;
}

.feature-card__title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-bright);
  margin-bottom: 8px;
}

.feature-card__text {
  font-size: 0.93rem;
  color: var(--text-dim);
  line-height: 1.6;
}

/* --- Install Section --- */
.install__tabs {
  display: flex;
  gap: 0;
  max-width: 700px;
  margin: 0 auto 0;
  border-bottom: 1px solid var(--border);
}

.install__tab {
  padding: 12px 24px;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-dim);
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  cursor: pointer;
  transition: all var(--transition);
}

.install__tab:hover {
  color: var(--text);
}

.install__tab.active {
  color: var(--green);
  border-bottom-color: var(--green);
}

.install__panel {
  max-width: 700px;
  margin: 0 auto;
  display: none;
}

.install__panel.active {
  display: block;
}

.code-block {
  position: relative;
  background: var(--bg-code);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 24px;
  margin-top: 0;
  overflow-x: auto;
}

.code-block code {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  line-height: 1.8;
  color: var(--text);
}

.code-block .code-comment {
  color: var(--text-dim);
}

.code-block .code-prompt {
  color: var(--green);
  user-select: none;
}

.code-block .code-cmd {
  color: var(--text-bright);
}

.code-block__copy {
  position: absolute;
  top: 12px;
  right: 12px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  padding: 4px 10px;
  border-radius: 4px;
  cursor: pointer;
  transition: all var(--transition);
}

.code-block__copy:hover {
  color: var(--green);
  border-color: var(--green-dim);
}

.code-block__copy.copied {
  color: var(--green);
  border-color: var(--green);
}

.install__note {
  text-align: center;
  margin-top: 16px;
  font-size: 0.85rem;
  color: var(--text-dim);
  font-style: italic;
}

/* --- Demo Section --- */
.demo__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  max-width: 900px;
  margin: 0 auto;
}

.demo-card {
  background: var(--bg-code);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  transition: border-color var(--transition);
}

.demo-card:hover {
  border-color: var(--border-light);
}

.demo-card__label {
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-bottom: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.demo-card__code {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--green);
  word-break: break-all;
}

.demo-card__desc {
  margin-top: 12px;
  font-size: 0.85rem;
  color: var(--text-dim);
  line-height: 1.5;
}

/* --- Comparison Table --- */
.comparison {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.comparison table {
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.comparison th,
.comparison td {
  padding: 14px 18px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.comparison th {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 600;
  white-space: nowrap;
}

.comparison th:first-child {
  color: var(--text);
}

.comparison th.highlight {
  color: var(--green);
}

.comparison td {
  color: var(--text-dim);
  white-space: nowrap;
}

.comparison td:first-child {
  color: var(--text);
  font-weight: 500;
}

.comparison tr:last-child td,
.comparison tr:last-child th {
  border-bottom: none;
}

.comparison .yes {
  color: var(--green);
  font-weight: 600;
}

.comparison .no {
  color: #555;
}

.comparison .partial {
  color: #f0c040;
}

.comparison tbody tr {
  transition: background var(--transition);
}

.comparison tbody tr:hover {
  background: var(--green-glow);
}

/* --- Footer --- */
.footer {
  border-top: 1px solid var(--border);
  padding: 40px 0;
  text-align: center;
}

.footer__links {
  display: flex;
  justify-content: center;
  gap: 32px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.footer__links a {
  color: var(--text-dim);
  font-size: 0.9rem;
}

.footer__links a:hover {
  color: var(--green);
}

.footer__copy {
  font-size: 0.85rem;
  color: var(--text-dim);
}

.footer__copy a {
  color: var(--text);
}

/* --- Responsive --- */
@media (max-width: 900px) {
  .features__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .demo__grid {
    grid-template-columns: 1fr;
    max-width: 500px;
  }

  .comparison table {
    font-size: 0.8rem;
  }

  .comparison th,
  .comparison td {
    padding: 10px 12px;
  }
}

@media (max-width: 640px) {
  .nav__links {
    display: none;
    position: absolute;
    top: 60px;
    left: 0;
    right: 0;
    background: rgba(10, 10, 10, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    flex-direction: column;
    padding: 20px 24px;
    gap: 16px;
    border-bottom: 1px solid var(--border);
  }

  .nav__links.open {
    display: flex;
  }

  .nav__toggle {
    display: block;
  }

  .features__grid {
    grid-template-columns: 1fr;
  }

  .hero {
    padding: 130px 0 70px;
  }

  .section {
    padding: 70px 0;
  }

  .hero__buttons {
    flex-direction: column;
    align-items: center;
  }

  .btn {
    width: 100%;
    max-width: 280px;
    justify-content: center;
  }

  .install__tabs {
    overflow-x: auto;
  }

  .install__tab {
    padding: 10px 16px;
    font-size: 0.8rem;
    white-space: nowrap;
  }
}

/* Scrollbar styling for code blocks */
.code-block::-webkit-scrollbar,
.comparison::-webkit-scrollbar {
  height: 6px;
}

.code-block::-webkit-scrollbar-track,
.comparison::-webkit-scrollbar-track {
  background: var(--bg-code);
}

.code-block::-webkit-scrollbar-thumb,
.comparison::-webkit-scrollbar-thumb {
  background: var(--border-light);
  border-radius: 3px;
}

/* Selection color */
::selection {
  background: var(--green);
  color: var(--bg);
}

::-moz-selection {
  background: var(--green);
  color: var(--bg);
}
