/* ============================================
   PITCH — Pavel Horák
   Stylesheet
   ============================================ */

:root {
  --bg: #fafafa;
  --bg-elevated: #ffffff;
  --bg-glass: rgba(255, 255, 255, 0.7);
  --bg-code: #f5f5f7;
  --border: rgba(0, 0, 0, 0.08);
  --border-strong: rgba(0, 0, 0, 0.12);
  --text: #0a0a0a;
  --text-muted: #6b7280;
  --text-subtle: #9ca3af;
  --accent: #2563eb;
  --accent-hover: #1d4ed8;
  --accent-soft: rgba(37, 99, 235, 0.08);
  --accent-glow: rgba(37, 99, 235, 0.25);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.08);
  --shadow-xl: 0 24px 60px rgba(0, 0, 0, 0.10);
  --mesh-1: rgba(37, 99, 235, 0.10);
  --mesh-2: rgba(139, 92, 246, 0.08);
  --font-sans: -apple-system, BlinkMacSystemFont, 'Inter', 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', monospace;
}

[data-theme="dark"] {
  --bg: #0a0a0b;
  --bg-elevated: #141416;
  --bg-glass: rgba(20, 20, 22, 0.7);
  --bg-code: #1c1c1e;
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.14);
  --text: #fafafa;
  --text-muted: #9ca3af;
  --text-subtle: #6b7280;
  --accent: #3b82f6;
  --accent-hover: #60a5fa;
  --accent-soft: rgba(59, 130, 246, 0.12);
  --accent-glow: rgba(59, 130, 246, 0.4);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.5);
  --shadow-xl: 0 24px 60px rgba(0, 0, 0, 0.6);
  --mesh-1: rgba(59, 130, 246, 0.18);
  --mesh-2: rgba(139, 92, 246, 0.14);
}

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

html, body {
  height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background 0.4s ease, color 0.4s ease;
  overflow-x: hidden;
}

body { min-height: 100vh; }

/* ============================================
   MESH BACKGROUND
   ============================================ */

.mesh-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.mesh-bg::before, .mesh-bg::after {
  content: '';
  position: absolute;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.7;
}

.mesh-bg::before {
  background: var(--mesh-1);
  top: -200px;
  left: -100px;
  animation: float1 20s ease-in-out infinite;
}

.mesh-bg::after {
  background: var(--mesh-2);
  bottom: -200px;
  right: -100px;
  animation: float2 25s ease-in-out infinite;
}

@keyframes float1 { 0%,100% { transform: translate(0,0); } 50% { transform: translate(100px,100px); } }
@keyframes float2 { 0%,100% { transform: translate(0,0); } 50% { transform: translate(-100px,-50px); } }

/* ============================================
   PAGE STRUCTURE
   ============================================ */

.page {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 32px;
  position: sticky;
  top: 0;
  background: var(--bg-glass);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  z-index: 10;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 600;
  font-size: 15px;
  letter-spacing: -0.01em;
}

.brand-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 16px var(--accent-glow);
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%,100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.7; transform: scale(1.2); }
}

.theme-toggle {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  width: 38px;
  height: 38px;
  border-radius: 10px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  color: var(--text-muted);
}

.theme-toggle:hover {
  border-color: var(--border-strong);
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

.theme-toggle svg { width: 18px; height: 18px; }
.theme-toggle .sun { display: none; }
.theme-toggle .moon { display: block; }
[data-theme="dark"] .theme-toggle .sun { display: block; }
[data-theme="dark"] .theme-toggle .moon { display: none; }

.main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 24px;
}

.unlocked-wrapper { width: 100%; display: flex; flex-direction: column; align-items: center; }

/* ============================================
   LOCKED SCREEN (PIN)
   ============================================ */

.locked-card {
  width: 100%;
  max-width: 440px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 48px 32px;
  box-shadow: var(--shadow-xl);
  text-align: center;
  animation: fadeInUp 0.6s ease;
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.identity { margin-bottom: 32px; }
.identity h1 { font-size: 28px; font-weight: 700; letter-spacing: -0.03em; margin-bottom: 8px; }
.identity .role { font-size: 14px; color: var(--text-muted); font-family: var(--font-mono); letter-spacing: 0.02em; }

.pin-prompt {
  margin-bottom: 24px;
  font-size: 13px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.pin-display { display: flex; justify-content: center; gap: 12px; margin-bottom: 32px; }

.pin-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid var(--border-strong);
  transition: all 0.2s ease;
}

.pin-dot.filled {
  background: var(--accent);
  border-color: var(--accent);
  box-shadow: 0 0 12px var(--accent-glow);
  transform: scale(1.1);
}

.pin-error .pin-dot {
  border-color: #ef4444;
  background: #ef4444;
  animation: shake 0.4s ease;
}

@keyframes shake { 0%,100% { transform: translateX(0); } 25% { transform: translateX(-8px); } 75% { transform: translateX(8px); } }

.keypad {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  max-width: 280px;
  margin: 0 auto;
}

.key {
  aspect-ratio: 1;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 50%;
  font-size: 26px;
  font-weight: 400;
  font-family: var(--font-sans);
  color: var(--text);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.key:hover { background: var(--accent-soft); border-color: var(--accent); transform: translateY(-1px); }
.key:active { transform: scale(0.92); background: var(--accent); color: white; }

.key.action { font-size: 14px; background: transparent; border-color: transparent; color: var(--text-muted); }
.key.action:hover { background: var(--bg); color: var(--text); border-color: var(--border); }
.key.delete svg { width: 24px; height: 24px; }

.locked-footer { margin-top: 32px; font-size: 12px; color: var(--text-subtle); }

.locked-error {
  margin-top: 16px;
  padding: 12px;
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.2);
  border-radius: 12px;
  font-size: 13px;
  color: #ef4444;
  display: none;
}

.locked-error.visible { display: block; animation: fadeInUp 0.3s ease; }

/* ============================================
   UNLOCKED — HERO
   ============================================ */

.unlocked { width: 100%; max-width: 880px; animation: fadeInUp 0.6s ease; }

.hero { text-align: center; margin-bottom: 56px; padding: 32px 0; }

.hero-tag {
  display: inline-block;
  padding: 6px 14px;
  background: var(--accent-soft);
  color: var(--accent);
  border-radius: 100px;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 20px;
  font-family: var(--font-mono);
}

.hero h1 {
  font-size: clamp(32px, 5vw, 48px);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: 16px;
}

.hero h1 .accent { color: var(--accent); }

.hero p {
  font-size: 17px;
  color: var(--text-muted);
  max-width: 540px;
  margin: 0 auto;
  line-height: 1.6;
}

/* ============================================
   QUESTIONS GRID
   ============================================ */

.questions-label {
  font-size: 11px;
  color: var(--text-subtle);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: 16px;
  font-family: var(--font-mono);
  text-align: center;
}

.questions-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 24px; }

@media (max-width: 768px) { .questions-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px) { .questions-grid { grid-template-columns: 1fr; } }

.question-btn {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 18px 20px;
  text-align: left;
  cursor: pointer;
  font-family: inherit;
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  transition: all 0.2s ease;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  line-height: 1.4;
}

.question-btn:hover { border-color: var(--accent); transform: translateY(-2px); box-shadow: var(--shadow-md); }

.question-btn .arrow { color: var(--text-subtle); transition: all 0.2s ease; flex-shrink: 0; }
.question-btn:hover .arrow { color: var(--accent); transform: translateX(4px); }

/* ============================================
   AI ROW
   ============================================ */

.ai-row {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 12px;
  margin-bottom: 24px;
}

@media (max-width: 480px) { .ai-row { grid-template-columns: 1fr; } }

.ai-btn {
  background: linear-gradient(135deg, var(--accent-soft) 0%, transparent 100%);
  border: 1px solid var(--accent);
  border-radius: 16px;
  padding: 18px 24px;
  cursor: pointer;
  font-family: inherit;
  font-size: 15px;
  font-weight: 500;
  color: var(--text);
  transition: all 0.2s ease;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  position: relative;
  overflow: hidden;
}

.ai-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, transparent 0%, var(--accent-glow) 100%);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.ai-btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.ai-btn:hover::before { opacity: 0.3; }

.ai-btn .label { display: flex; align-items: center; gap: 10px; position: relative; }
.ai-btn .ai-icon { width: 20px; height: 20px; color: var(--accent); }

.ai-btn .live-tag {
  font-size: 10px;
  font-family: var(--font-mono);
  background: var(--accent);
  color: white;
  padding: 2px 8px;
  border-radius: 100px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.ai-btn:disabled,
.ai-btn[disabled] {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.prompt-btn {
  background: transparent;
  border: 1px solid var(--border-strong);
  border-radius: 16px;
  padding: 18px 20px;
  cursor: pointer;
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.prompt-btn:hover {
  border-color: var(--text-muted);
  color: var(--text);
  transform: translateY(-2px);
}

.prompt-btn svg { width: 14px; height: 14px; }

.counter { text-align: center; font-family: var(--font-mono); font-size: 12px; color: var(--text-muted); margin-bottom: 24px; }
.counter .num { color: var(--accent); font-weight: 600; }

/* ============================================
   AI HISTORY (sbalovací seznam předchozích rešerší)
   ============================================ */

.ai-history {
  margin-bottom: 24px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--bg-elevated);
  overflow: hidden;
  transition: border-color 0.2s ease;
}

.ai-history-toggle {
  width: 100%;
  background: transparent;
  border: none;
  padding: 14px 18px;
  cursor: pointer;
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 10px;
  transition: color 0.2s ease, background 0.2s ease;
}

.ai-history-toggle:hover { color: var(--text); background: var(--bg); }

.ai-history-toggle .history-icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.ai-history-toggle > span {
  flex: 1;
  text-align: left;
}

.ai-history-toggle .history-chevron {
  width: 14px;
  height: 14px;
  transition: transform 0.3s ease;
  flex-shrink: 0;
}

.ai-history.expanded .ai-history-toggle .history-chevron {
  transform: rotate(180deg);
}

.ai-history-list {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease;
  border-top: 1px solid transparent;
}

.ai-history.expanded .ai-history-list {
  max-height: 800px;
  border-top-color: var(--border);
}

.history-entry {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--border);
  padding: 12px 18px;
  cursor: pointer;
  font-family: inherit;
  font-size: 13px;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 10px;
  transition: background 0.2s ease;
  text-align: left;
}

.history-entry:last-child { border-bottom: none; }

.history-entry:hover { background: var(--accent-soft); }

.history-entry-icon {
  width: 14px;
  height: 14px;
  color: var(--text-muted);
  flex-shrink: 0;
}

.history-entry-date {
  flex: 1;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text);
  letter-spacing: 0.02em;
}

.history-entry-arrow {
  color: var(--text-subtle);
  transition: transform 0.2s ease;
  flex-shrink: 0;
}

.history-entry:hover .history-entry-arrow {
  color: var(--accent);
  transform: translateX(2px);
}

/* Banner uvnitř answer panelu když je zobrazen historický záznam */
.history-banner {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  margin-bottom: 20px;
  background: var(--accent-soft);
  border: 1px solid var(--accent-soft);
  border-radius: 10px;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--accent);
  letter-spacing: 0.02em;
}

.history-banner svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

/* ============================================
   ANSWER PANEL
   ============================================ */

.answer-panel {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 32px;
  margin-bottom: 32px;
  box-shadow: var(--shadow-md);
  animation: fadeInUp 0.4s ease;
  display: none;
}

.answer-panel.visible { display: block; }

.answer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

.answer-title {
  font-size: 13px;
  font-family: var(--font-mono);
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.answer-close {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px;
  border-radius: 6px;
  transition: all 0.2s ease;
}

.answer-close:hover { background: var(--bg); color: var(--text); }

.answer-content { font-size: 15px; line-height: 1.7; color: var(--text); }
.answer-content p { margin-bottom: 14px; }
.answer-content p:last-child { margin-bottom: 0; }
.answer-content strong { color: var(--text); font-weight: 600; }
.answer-content a { color: var(--accent); text-decoration: none; border-bottom: 1px solid var(--accent-soft); transition: border-color 0.2s ease; }
.answer-content a:hover { border-bottom-color: var(--accent); }
.answer-content ul { margin: 12px 0; padding-left: 20px; }
.answer-content li { margin-bottom: 6px; }

/* Read more — pill button vpravo */
.read-more {
  margin-top: 16px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 100px;
  padding: 6px 14px;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  float: right;
}

.read-more:hover { border-color: var(--accent); color: var(--accent); }
.read-more svg { width: 12px; height: 12px; transition: transform 0.3s ease; }
.read-more.expanded svg { transform: rotate(180deg); }

.career-section::after,
.answer-content::after { content: ''; display: block; clear: both; }

.detail-content { max-height: 0; overflow: hidden; transition: max-height 0.5s ease; clear: both; }
.detail-content.expanded { max-height: 5000px; }
.detail-content-inner { padding-top: 20px; margin-top: 4px; }

/* AI streaming */
.streaming-log {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--text-muted);
  background: var(--bg);
  border-radius: 10px;
  padding: 16px;
  margin-bottom: 16px;
  border: 1px solid var(--border);
}

.streaming-log .log-line { margin-bottom: 4px; opacity: 0; animation: fadeIn 0.3s ease forwards; }
.streaming-log .log-line.done::before { content: '✓ '; color: #10b981; }
.streaming-log .log-line.active::before { content: '⟳ '; color: var(--accent); animation: spin 1s linear infinite; display: inline-block; }

@keyframes spin { to { transform: rotate(360deg); } }
@keyframes fadeIn { to { opacity: 1; } }

.prompt-link {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  font-size: 13px;
  color: var(--text-muted);
  text-align: center;
}

.prompt-link a {
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px dashed var(--accent-soft);
  cursor: pointer;
  transition: border-color 0.2s ease;
}

.prompt-link a:hover { border-bottom-color: var(--accent); }

/* ============================================
   ABOUT SECTION
   ============================================ */

.about {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 40px;
  margin-top: 64px;
  margin-bottom: 32px;
  box-shadow: var(--shadow-md);
}

.about-label {
  font-size: 11px;
  color: var(--text-subtle);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: 24px;
  font-family: var(--font-mono);
  text-align: center;
}

.about-header {
  display: flex;
  gap: 32px;
  align-items: flex-start;
  margin-bottom: 32px;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--border);
}

@media (max-width: 600px) {
  .about-header { flex-direction: column; align-items: center; text-align: center; gap: 20px; }
}

.about-photo {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  border: 2px solid var(--border);
  box-shadow: var(--shadow-md);
}

.about-intro { flex: 1; padding-top: 8px; }
.about-intro h2 { font-size: 28px; font-weight: 700; letter-spacing: -0.02em; margin-bottom: 6px; }
.about-intro .role { font-size: 14px; color: var(--text-muted); font-family: var(--font-mono); letter-spacing: 0.02em; }

.career-section {
  margin-bottom: 28px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--border);
}

.career-section:last-of-type { margin-bottom: 0; padding-bottom: 0; border-bottom: none; }

.career-section h3 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 12px;
  letter-spacing: -0.01em;
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
}

.career-section h3 .years { color: var(--accent); font-family: var(--font-mono); font-size: 13px; font-weight: 500; }
.career-section .lead { font-size: 15px; color: var(--text); line-height: 1.7; }

.career-section .detail { margin-top: 16px; font-size: 14px; color: var(--text-muted); line-height: 1.7; }
.career-section .detail p { margin-bottom: 12px; }
.career-section .detail p:last-child { margin-bottom: 0; }
.career-section .detail strong { color: var(--text); font-weight: 600; }
.career-section .detail ul { margin: 12px 0; padding-left: 20px; }
.career-section .detail li { margin-bottom: 6px; }

/* Contact */
.contact-block {
  margin-top: 32px;
  padding-top: 32px;
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: flex-start;
}

@media (max-width: 600px) { .contact-block { align-items: center; } }

.contact-row {
  font-size: 14px;
  color: var(--text);
  font-family: var(--font-mono);
  display: flex;
  align-items: center;
  gap: 8px;
}

.contact-row a { color: inherit; text-decoration: none; transition: color 0.2s ease; }
.contact-row a:hover { color: var(--accent); }

.contact-row .label {
  color: var(--text-subtle);
  font-size: 12px;
  min-width: 80px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.save-contact-btn {
  margin-top: 8px;
  background: var(--accent);
  color: white;
  border: none;
  padding: 12px 24px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.save-contact-btn:hover { background: var(--accent-hover); transform: translateY(-1px); box-shadow: 0 8px 20px var(--accent-glow); }
.save-contact-btn svg { width: 16px; height: 16px; }

/* Links list */
.links-block { margin-top: 32px; padding-top: 32px; border-top: 1px solid var(--border); }

.links-label {
  font-size: 11px;
  color: var(--text-subtle);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: 16px;
  font-family: var(--font-mono);
}

.links-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.link-row {
  display: flex;
  align-items: baseline;
  gap: 16px;
  padding: 8px 0;
  text-decoration: none;
  transition: all 0.2s ease;
  border-bottom: 1px solid transparent;
}

.link-row:hover { border-bottom-color: var(--border); }

.link-row .url {
  font-family: var(--font-mono);
  font-size: 14px;
  color: var(--text);
  font-weight: 500;
  min-width: 180px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: color 0.2s ease;
}

.link-row:hover .url { color: var(--accent); }

.link-row .url svg { width: 12px; height: 12px; opacity: 0.5; flex-shrink: 0; }

.link-row .description {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.5;
}

@media (max-width: 600px) {
  .link-row { flex-direction: column; align-items: flex-start; gap: 4px; }
  .link-row .url { min-width: 0; }
}

/* ============================================
   MODALS
   ============================================ */

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 100;
  padding: 24px;
}

.modal-overlay.visible { display: flex; animation: fadeIn 0.25s ease forwards; opacity: 1; }

.modal {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 32px;
  max-width: 360px;
  width: 100%;
  box-shadow: var(--shadow-xl);
  position: relative;
  animation: modalIn 0.3s ease;
}

.modal.large {
  max-width: 720px;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
}

@keyframes modalIn {
  from { opacity: 0; transform: translateY(20px) scale(0.96); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@media (max-width: 600px) {
  .modal-overlay { align-items: flex-end; padding: 0; }
  .modal { max-width: 100%; border-radius: 24px 24px 0 0; animation: bottomSheetIn 0.3s ease; }
  .modal.large { max-height: 92vh; }
  @keyframes bottomSheetIn {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
  }
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: var(--bg);
  border: 1px solid var(--border);
  width: 32px;
  height: 32px;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: all 0.2s ease;
  z-index: 2;
}

.modal-close:hover { background: var(--accent-soft); color: var(--accent); border-color: var(--accent); }
.modal-close svg { width: 16px; height: 16px; }

.modal h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 20px;
  letter-spacing: -0.02em;
  text-align: center;
}

.modal.large h3 { text-align: left; padding-right: 40px; flex-shrink: 0; }

.qr-container {
  width: 220px;
  height: 220px;
  margin: 0 auto 16px;
  padding: 16px;
  background: white;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
}

.qr-container img, .qr-container canvas { max-width: 100%; height: auto; }

.qr-hint { text-align: center; font-size: 13px; color: var(--text-muted); margin-bottom: 24px; }

.modal-divider {
  display: flex;
  align-items: center;
  margin: 20px 0;
  font-size: 11px;
  color: var(--text-subtle);
  font-family: var(--font-mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.modal-divider::before, .modal-divider::after { content: ''; flex: 1; height: 1px; background: var(--border); }
.modal-divider span { padding: 0 12px; }

.download-btn {
  width: 100%;
  background: var(--bg);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 14px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.download-btn:hover { border-color: var(--accent); color: var(--accent); }
.download-btn svg { width: 16px; height: 16px; }

/* Prompt modal */
.modal.large .modal-intro {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 20px;
  flex-shrink: 0;
}

.prompt-content {
  flex: 1;
  overflow-y: auto;
  background: var(--bg-code);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.7;
  color: var(--text);
  white-space: pre-wrap;
  word-wrap: break-word;
}

.prompt-section-label {
  display: inline-block;
  background: var(--accent);
  color: white;
  font-size: 10px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 100px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 12px;
  margin-top: 16px;
}

.prompt-section-label:first-child { margin-top: 0; }

/* ============================================
   FOOTER
   ============================================ */

.foot {
  text-align: center;
  font-size: 13px;
  color: var(--text-muted);
  padding: 32px 24px;
  font-family: var(--font-mono);
  border-top: 1px solid var(--border);
  background: var(--bg-elevated);
  margin-top: 64px;
}

.foot a { color: var(--text); text-decoration: none; border-bottom: 1px solid var(--border); transition: all 0.2s ease; }
.foot a:hover { color: var(--accent); border-bottom-color: var(--accent); }

/* ============================================
   UTILITIES
   ============================================ */

.hidden { display: none !important; }

@media (max-width: 380px) {
  .locked-card { padding: 32px 20px; }
  .keypad { gap: 10px; }
  .key { font-size: 22px; }
  .about { padding: 24px; }
}
