@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500&family=JetBrains+Mono:wght@400;500&display=swap');

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

:root {
  --white: #ffffff;
  --ink: #111111;
  --mid: #6b6b6b;
  --faint: #f4f4f4;
  --line: #e5e5e5;
  --blue: #2563eb;
  --blue-bg: #eff6ff;
  --green: #16a34a;
  --red: #dc2626;
  --amber: #d97706;
  --radius: 8px;
  --mono: 'JetBrains Mono', monospace;
  --sans: 'Inter', sans-serif;
}

html { font-size: 16px; -webkit-font-smoothing: antialiased; }
body { font-family: var(--sans); color: var(--ink); background: var(--white); line-height: 1.6; }

a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }

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

/* NAV */
nav { border-bottom: 1px solid var(--line); }
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 56px; }
.nav-logo { font-family: var(--mono); font-size: 14px; font-weight: 500; color: var(--ink); letter-spacing: -0.02em; }
.nav-logo span { color: var(--blue); }
.nav-links { display: flex; gap: 28px; }
.nav-links a { font-size: 14px; color: var(--mid); transition: color 0.15s; }
.nav-links a:hover, .nav-links a.active { color: var(--ink); text-decoration: none; }

/* FOOTER */
footer { border-top: 1px solid var(--line); margin-top: 80px; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; height: 56px; font-size: 13px; color: var(--mid); }
.footer-inner a { color: var(--mid); }
.footer-inner a:hover { color: var(--ink); text-decoration: none; }

/* GENERATOR EMBED */
.gen-wrap { max-width: 560px; }

.mode-tabs { display: flex; gap: 4px; background: var(--faint); border: 1px solid var(--line); border-radius: var(--radius); padding: 3px; margin-bottom: 20px; }
.tab { flex: 1; padding: 7px; font-size: 13px; font-family: var(--sans); border: none; border-radius: 6px; background: transparent; color: var(--mid); cursor: pointer; transition: background 0.15s, color 0.15s; }
.tab.active { background: var(--white); color: var(--ink); font-weight: 500; border: 1px solid var(--line); }

.output-box { background: var(--faint); border: 1px solid var(--line); border-radius: 12px; padding: 20px; margin-bottom: 20px; }
.pw-display { font-family: var(--mono); font-size: 17px; color: var(--ink); word-break: break-all; min-height: 26px; letter-spacing: 0.02em; margin-bottom: 14px; line-height: 1.5; }
.pw-display.phrase { font-family: var(--sans); font-size: 16px; letter-spacing: 0; }
.word-pill { display: inline-block; background: var(--white); border: 1px solid var(--line); border-radius: 6px; padding: 1px 7px; margin: 2px 2px 2px 0; font-size: 15px; color: var(--ink); }

.meta-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.strength-row { display: flex; align-items: center; gap: 8px; }
.dots { display: flex; gap: 4px; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--line); transition: background 0.2s; }
.dot.weak { background: var(--red); }
.dot.fair { background: var(--amber); }
.dot.good { background: #65a30d; }
.dot.strong { background: var(--green); }
.slabel { font-family: var(--mono); font-size: 11px; color: var(--mid); min-width: 40px; }

.actions { display: flex; gap: 6px; }
.ibtn { display: flex; align-items: center; gap: 5px; font-size: 12px; font-family: var(--mono); color: var(--mid); background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 5px 10px; cursor: pointer; transition: background 0.15s, color 0.15s, border-color 0.15s; white-space: nowrap; }
.ibtn:hover { border-color: #ccc; color: var(--ink); }
.ibtn.ok { color: var(--green); border-color: #86efac; }

.controls { display: flex; flex-direction: column; gap: 16px; }
.crow { display: flex; flex-direction: column; gap: 8px; }
.clabel { display: flex; justify-content: space-between; align-items: center; font-size: 13px; color: var(--mid); }
.clabel strong { color: var(--ink); font-family: var(--mono); font-size: 13px; font-weight: 500; }

.checks { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.ck { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--mid); cursor: pointer; user-select: none; padding: 8px 10px; border: 1px solid var(--line); border-radius: var(--radius); transition: border-color 0.15s, background 0.15s; }
.ck:hover { border-color: #bbb; background: var(--faint); }
.ck.on { border-color: #bfdbfe; background: var(--blue-bg); color: var(--ink); }
.ckbox { width: 15px; height: 15px; border-radius: 3px; border: 1px solid #ccc; display: flex; align-items: center; justify-content: center; flex-shrink: 0; font-size: 10px; color: transparent; transition: background 0.15s, color 0.15s, border-color 0.15s; }
.ck.on .ckbox { background: var(--blue); border-color: var(--blue); color: white; }

.sep { height: 1px; background: var(--line); }

.genbtn { width: 100%; margin-top: 4px; padding: 11px; background: var(--ink); color: var(--white); border: none; border-radius: var(--radius); font-size: 14px; font-family: var(--sans); font-weight: 500; cursor: pointer; transition: opacity 0.15s; letter-spacing: -0.01em; }
.genbtn:hover { opacity: 0.82; }
.genbtn:active { transform: scale(0.99); opacity: 0.7; }

.history-section { margin-top: 28px; }
.hist-hdr { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.hist-hdr span { font-family: var(--mono); font-size: 11px; color: var(--mid); text-transform: uppercase; letter-spacing: 0.08em; }
.hist-clear { font-size: 12px; font-family: var(--sans); color: var(--mid); background: none; border: none; cursor: pointer; }
.hist-clear:hover { color: var(--red); }
.hist-list { display: flex; flex-direction: column; gap: 1px; }
.hist-row { display: flex; align-items: center; gap: 10px; padding: 9px 12px; background: var(--faint); border: 1px solid var(--line); border-radius: 6px; }
.hist-pw { flex: 1; font-family: var(--mono); font-size: 13px; color: var(--ink); word-break: break-all; min-width: 0; }
.hist-pw.phrase { font-family: var(--sans); }
.hist-meta { font-family: var(--mono); font-size: 11px; color: var(--mid); white-space: nowrap; flex-shrink: 0; }
.hist-copy { background: none; border: none; color: var(--mid); cursor: pointer; padding: 2px 6px; border-radius: 4px; font-size: 13px; }
.hist-copy:hover { color: var(--ink); background: var(--line); }
.hist-empty { font-size: 13px; color: var(--mid); text-align: center; padding: 24px 0; border: 1px dashed var(--line); border-radius: var(--radius); font-family: var(--mono); }

input[type="range"] { width: 100%; accent-color: var(--ink); }

/* PAGE SECTIONS */
.hero { padding: 64px 0 48px; }
.eyebrow { font-family: var(--mono); font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--mid); margin-bottom: 16px; }
.hero h1 { font-size: clamp(32px, 5vw, 46px); font-weight: 500; line-height: 1.1; letter-spacing: -0.03em; color: var(--ink); margin-bottom: 16px; }
.hero h1 em { font-style: normal; color: var(--mid); }
.hero-sub { font-size: 16px; color: var(--mid); max-width: 440px; line-height: 1.6; margin-bottom: 40px; }
.divider { height: 1px; background: var(--line); margin: 56px 0; }

.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 32px; padding: 0 0 16px; }
.feature-label { font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--mid); margin-bottom: 8px; }
.feature p { font-size: 14px; color: var(--mid); line-height: 1.6; }
.feature strong { color: var(--ink); font-weight: 500; display: block; font-size: 15px; margin-bottom: 4px; }

/* ABOUT PAGE */
.page-hero { padding: 56px 0 40px; border-bottom: 1px solid var(--line); margin-bottom: 48px; }
.page-hero h1 { font-size: 36px; font-weight: 500; letter-spacing: -0.03em; margin-bottom: 12px; }
.page-hero p { font-size: 16px; color: var(--mid); max-width: 480px; }

.prose { max-width: 560px; }
.prose h2 { font-size: 18px; font-weight: 500; letter-spacing: -0.02em; margin: 40px 0 12px; }
.prose h2:first-child { margin-top: 0; }
.prose p { font-size: 15px; color: var(--mid); line-height: 1.75; margin-bottom: 16px; }
.prose p strong { color: var(--ink); font-weight: 500; }

/* FAQ */
.faq-list { display: flex; flex-direction: column; }
.faq-item { border-top: 1px solid var(--line); padding: 20px 0; cursor: pointer; }
.faq-item:last-child { border-bottom: 1px solid var(--line); }
.faq-q { display: flex; justify-content: space-between; align-items: center; gap: 16px; font-size: 15px; font-weight: 500; color: var(--ink); letter-spacing: -0.01em; user-select: none; }
.faq-icon { font-size: 18px; color: var(--mid); flex-shrink: 0; transition: transform 0.2s; font-weight: 400; }
.faq-a { font-size: 14px; color: var(--mid); line-height: 1.7; max-height: 0; overflow: hidden; transition: max-height 0.25s ease, padding-top 0.25s; }
.faq-item.open .faq-icon { transform: rotate(45deg); }
.faq-item.open .faq-a { max-height: 300px; padding-top: 12px; }

/* GENERATOR PAGE */
.gen-page { padding: 56px 0 80px; }
.gen-page h1 { font-size: 28px; font-weight: 500; letter-spacing: -0.025em; margin-bottom: 8px; }
.gen-page .sub { font-size: 15px; color: var(--mid); margin-bottom: 40px; }

@media (max-width: 600px) {
  .nav-links { gap: 16px; }
  .checks { grid-template-columns: 1fr; }
  .features { grid-template-columns: 1fr; gap: 24px; }
  .footer-inner { flex-direction: column; gap: 8px; height: auto; padding: 20px 0; text-align: center; }
}
