/* ── Google Fonts ── */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;600;700&family=Roboto+Condensed:wght@400;700&display=swap');

/* ── Design tokens (matches original Kadence palette) ── */
:root {
  --blue:       #3296ff;
  --blue-dark:  #003174;
  --white:      #ffffff;
  --bg-light:   #f7fafc;  /* palette4 */
  --bg-mid:     #edf2f7;  /* palette5 */
  --border:     #cbd2d9;  /* palette6 */
  --text:       #f7fafc;  /* palette4 – near-white on dark bg */
  --text-muted: #edf2f7;  /* palette5 */
  --bg:         #252c39;  /* palette8 – body bg */
  --bg-content: #1a202c;  /* palette9 – card/section bg */
  --bg-card:    #2d3748;  /* palette7 – slightly lighter card */
}

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.6 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; height: auto; display: block; }

/* ── Typography ── */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Montserrat', sans-serif;
  color: var(--white);
  line-height: 1.3;
  margin-top: 0;
}
h1 { font-size: 42px; font-weight: 700; }
h2 { font-size: 32px; font-weight: 700; }
h3 { font-size: 20px; font-weight: 600; font-family: 'Roboto Condensed', sans-serif; }
h4 { font-size: 14px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--blue); }

/* ── Layout ── */
.site-wrap   { display: flex; flex-direction: column; min-height: 100vh; }
main         { flex: 1; }
.container   { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* ── Header / nav ── */
.site-header {
  background: var(--bg-content);
  border-bottom: 1px solid rgba(255,255,255,.08);
  position: sticky;
  top: 0;
  z-index: 100;
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 14px;
  padding-bottom: 14px;
  gap: 16px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  font-size: 18px;
  color: var(--white);
  text-decoration: none;
}
.brand img { width: 36px; height: 36px; border-radius: 6px; }
.brand:hover { text-decoration: none; }
.main-nav { display: flex; gap: 4px; flex-wrap: wrap; }
.main-nav a {
  font-family: 'Montserrat', sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
  padding: 6px 12px;
  border-radius: 6px;
  transition: background .15s, color .15s;
}
.main-nav a:hover { background: rgba(50,150,255,.15); color: var(--white); text-decoration: none; }
.main-nav a.active { color: var(--white); }

/* ── Hero – blue gradient with wave ── */
.hero {
  background: linear-gradient(130deg, var(--blue) 0%, var(--blue-dark) 100%);
  color: var(--white);
  text-align: center;
  padding: 72px 24px 0;
  position: relative;
}
.hero h1 { font-size: 48px; margin: 0 0 12px; color: var(--white); }
.hero .sub {
  font-size: 18px;
  color: rgba(255,255,255,.88);
  max-width: 680px;
  margin: 0 auto 8px;
}
.hero a { color: var(--white); font-weight: 600; text-decoration: underline; }
.hero-wave {
  margin-top: 40px;
  line-height: 0;
}
.hero-wave svg { display: block; width: 100%; }

/* ── Password generator ── */
.pwgen-wrap { background: var(--bg-content); padding: 0 24px 48px; }
.pwgen {
  max-width: 720px;
  margin: 0 auto;
  background: var(--bg-card);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 16px;
  padding: 28px 32px;
  transform: translateY(-32px);
  box-shadow: 0 20px 60px rgba(0,0,0,.4);
}
.pwgen-mode-toggle {
  display: flex;
  background: var(--bg-content);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 10px;
  padding: 4px;
  margin-bottom: 24px;
  gap: 4px;
}
.pwgen-mode-tab {
  flex: 1;
  cursor: pointer;
}
.pwgen-mode-tab input[type=radio] {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}
.pwgen-mode-tab input[type=radio]:focus-visible + span {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
}
.pwgen-mode-tab span {
  display: block;
  text-align: center;
  padding: 8px 12px;
  border-radius: 7px;
  font-size: 14px;
  font-weight: 600;
  font-family: 'Montserrat', sans-serif;
  color: var(--text-muted);
  transition: background .15s, color .15s;
  user-select: none;
}
.pwgen-mode-tab input[type=radio]:checked + span {
  background: var(--blue);
  color: var(--white);
}
.pwgen-columns {
  display: flex;
  gap: 32px;
  align-items: flex-start;
}
.pwgen-left {
  flex: 1 1 0;
  display: flex;
  flex-direction: column;
}
.pwgen-right {
  flex: 0 0 220px;
  display: flex;
  flex-direction: column;
}
.hidden { display: none !important; }
.pwgen-strength {
  font-size: 12px;
  color: var(--text-muted);
  margin: 0 0 12px;
  min-height: 16px;
}
.pwgen-strength--velmi-silné { color: #48bb78; }
.pwgen-strength--silné       { color: #68d391; }
.pwgen-strength--dobré       { color: #f6ad55; }
.pwgen-strength--slabé       { color: #fc8181; }
.pwgen-select {
  width: 100%;
  background: var(--bg-content);
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 6px;
  color: var(--white);
  font-size: 14px;
  padding: 7px 10px;
  font-family: inherit;
  cursor: pointer;
  margin-bottom: 4px;
}
.pwgen-select:focus { outline: none; border-color: var(--blue); }
.pwgen-label {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--text-muted);
  margin: 0 0 8px;
}
.pwgen-section-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--white);
  margin: 0 0 10px;
}
.pwgen .pw {
  display: block;
  font-family: "SF Mono", Consolas, Menlo, monospace;
  font-size: 20px;
  word-break: break-all;
  background: var(--bg-content);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 10px;
  padding: 16px;
  min-height: 80px;
  margin-bottom: 16px;
  color: var(--white);
  letter-spacing: .04em;
  flex: 1;
}
.pwgen-opts {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 0 0 4px;
  font-size: 14px;
  color: var(--text-muted);
}
.pwgen-opts label { cursor: pointer; display: flex; align-items: center; gap: 8px; }
.pwgen-opts input[type=checkbox] { accent-color: var(--blue); width: 16px; height: 16px; flex-shrink: 0; }
.pwgen-len {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 6px 0 16px;
}
.pwgen-len input[type=range] { flex: 1; accent-color: var(--blue); min-width: 0; }
.pwgen-len input[type=number] {
  width: 52px;
  background: var(--bg-content);
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 6px;
  color: var(--white);
  font-size: 14px;
  text-align: center;
  padding: 4px 6px;
  -moz-appearance: textfield;
}
.pwgen-len input[type=number]::-webkit-inner-spin-button,
.pwgen-len input[type=number]::-webkit-outer-spin-button { opacity: 1; }
.btn {
  cursor: pointer;
  border: none;
  border-radius: 8px;
  padding: 12px 20px;
  font-size: 15px;
  font-weight: 700;
  font-family: 'Montserrat', sans-serif;
  transition: background .15s, transform .1s;
}
.btn-gen {
  background: var(--blue);
  color: var(--white);
  width: 100%;
  font-size: 16px;
  padding: 14px;
}
.btn-gen:hover { background: #1a7ce6; transform: translateY(-1px); }
.btn-copy {
  background: transparent;
  color: var(--blue);
  border: 1px solid var(--blue);
  padding: 6px 14px;
  font-size: 13px;
  margin-bottom: 8px;
}
.btn-copy:hover { background: rgba(50,150,255,.15); }

/* ── Sections ── */
.section { padding: 56px 0; }
.section--alt { background: var(--bg-content); }
.section h2 { margin-bottom: 8px; }
.section-lead { color: var(--text-muted); margin: 0 0 28px; font-size: 17px; }
.section-link { display: inline-block; margin-top: 20px; color: var(--blue); font-weight: 600; }

/* ── Security steps ── */
.security-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin-top: 24px;
}
.step-card {
  background: var(--bg-card);
  border: 1px solid rgba(255,255,255,.08);
  border-left: 4px solid var(--blue);
  border-radius: 12px;
  padding: 22px 20px;
}
.step-card h3 { color: var(--white); margin-bottom: 8px; font-size: 18px; }
.step-card p { color: var(--text-muted); margin: 0; font-size: 15px; }

/* ── Tool / article cards ── */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 22px;
  margin-top: 24px;
}
.card {
  background: var(--bg-card);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform .2s, box-shadow .2s;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 12px 40px rgba(0,0,0,.35); }
.card img { width: 100%; height: 180px; object-fit: cover; }
.card-body { padding: 18px 20px; flex: 1; display: flex; flex-direction: column; }
.card-cat {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .07em;
  font-weight: 700;
  color: var(--blue);
  margin: 0 0 6px;
}
.card-cat a { color: var(--blue); }
.card h3 { font-size: 17px; margin: 0 0 8px; color: var(--white); }
.card h3 a { color: var(--white); }
.card h3 a:hover { color: var(--blue); text-decoration: none; }
.card p { color: var(--text-muted); font-size: 14px; margin: 0 0 12px; flex: 1; }
.card-meta { font-size: 13px; color: var(--border); margin-top: auto; }
.card .btn-gen {
  margin-top: 12px;
  font-size: 14px;
  padding: 10px 16px;
  border-radius: 8px;
  display: inline-block;
  text-align: center;
  width: auto;
  color: var(--white);
  text-decoration: none;
}

/* ── Article / post ── */
.post { max-width: 760px; margin: 0 auto; padding: 48px 0 64px; }
.post h1 { font-size: 34px; margin: 8px 0 6px; }
.post-cat a { font-size: 12px; text-transform: uppercase; letter-spacing: .05em; font-weight: 700; color: var(--blue); }
.post-meta { color: var(--border); font-size: 14px; margin: 0 0 20px; }
.post-hero { border-radius: 14px; margin: 16px 0 28px; width: 100%; height: 340px; object-fit: cover; }
.post-body { font-size: 17px; line-height: 1.75; color: var(--text-muted); }
.post-body h2, .post-body h3 { color: var(--white); }
.post-body a { color: var(--blue); }
.post-body ul, .post-body ol { padding-left: 22px; }
.post-body li { margin: 6px 0; }
.back { margin-top: 36px; }
.back a { color: var(--blue); font-weight: 600; }

/* ── Article list (/clanky/) ── */
.article-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
  margin-top: 24px;
}

/* ── Tool grid (/nastroje/) ── */
.tool-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 22px;
  margin-top: 20px;
}

/* ── Nastroje section dividers ── */
.nastroje-section { margin-bottom: 56px; }
.nastroje-section h2 { border-bottom: 2px solid rgba(50,150,255,.3); padding-bottom: 10px; margin-bottom: 12px; }
.nastroje-section ul { color: var(--text-muted); padding-left: 22px; }
.nastroje-section ul li { margin: 6px 0; }

/* ── Contact form ── */
.contact-form { max-width: 600px; }
.contact-form label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 14px; color: var(--text-muted); }
.contact-form input,
.contact-form textarea {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 8px;
  padding: 11px 14px;
  font-size: 15px;
  font-family: inherit;
  color: var(--white);
  margin-top: 4px;
  display: block;
}
.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--blue);
}
.contact-form textarea { resize: vertical; }

/* ── Footer ── */
.site-footer {
  background: var(--bg-content);
  border-top: 1px solid rgba(255,255,255,.07);
  padding: 28px 24px;
  text-align: center;
  color: var(--border);
  font-size: 14px;
}
.site-footer nav { margin-top: 10px; }
.site-footer nav a { margin: 0 10px; color: var(--border); }
.site-footer nav a:hover { color: var(--white); text-decoration: none; }

/* ── 404 ── */
.hero-404 { padding-bottom: 72px; }

/* ── Responsive ── */
@media (max-width: 640px) {
  h1, .hero h1 { font-size: 32px; }
  h2 { font-size: 26px; }
  .hero { padding-top: 48px; }
  .pwgen { transform: translateY(-20px); padding: 24px 20px; }
  .pwgen-columns { flex-direction: column; }
  .pwgen-right { flex: none; width: 100%; }
  .main-nav a { padding: 5px 8px; font-size: 13px; }
}
