/* ===== TOOLBOX WEBSITE - GLOBAL DESIGN SYSTEM ===== */

/* CSS Custom Properties */
:root {
  --bg-primary: #0a0a0f;
  --bg-secondary: #12121a;
  --bg-card: #1a1a2e;
  --bg-card-hover: #222240;
  --bg-input: #16162a;
  --border-color: #2a2a4a;
  --border-focus: #6c5ce7;
  --text-primary: #e8e8f0;
  --text-secondary: #8888a8;
  --text-muted: #55556a;
  --accent-primary: #6c5ce7;
  --accent-secondary: #a29bfe;
  --accent-gradient: linear-gradient(135deg, #6c5ce7, #a29bfe);
  --accent-glow: rgba(108, 92, 231, 0.3);
  --success: #00cec9;
  --warning: #fdcb6e;
  --danger: #ff7675;
  --info: #74b9ff;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.3);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.4);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.5);
  --shadow-glow: 0 0 20px var(--accent-glow);
  --transition-fast: 0.15s ease;
  --transition-normal: 0.25s ease;
  --transition-slow: 0.4s ease;
  --font-main: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', 'Cascadia Code', monospace;
  --max-width: 1200px;
  --header-height: 64px;
}

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

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

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

a {
  color: var(--accent-secondary);
  text-decoration: none;
  transition: color var(--transition-fast);
}
a:hover {
  color: var(--accent-primary);
}

/* Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: var(--bg-secondary);
}
::-webkit-scrollbar-thumb {
  background: var(--border-color);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--accent-primary);
}

/* Selection */
::selection {
  background: var(--accent-primary);
  color: #fff;
}

/* ===== HEADER ===== */
.header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(10, 10, 15, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-color);
  height: var(--header-height);
  display: flex;
  align-items: center;
}

.header-inner {
  max-width: var(--max-width);
  width: 100%;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
  white-space: nowrap;
}
.logo:hover {
  color: var(--text-primary);
}
.logo-icon {
  width: 32px;
  height: 32px;
  background: var(--accent-gradient);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

/* Search Bar (Header) */
.header-search {
  flex: 1;
  max-width: 480px;
  position: relative;
}
.header-search input {
  width: 100%;
  padding: 8px 16px 8px 40px;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xl);
  color: var(--text-primary);
  font-size: 0.9rem;
  font-family: var(--font-main);
  transition: all var(--transition-normal);
  outline: none;
}
.header-search input:focus {
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px var(--accent-glow);
}
.header-search input::placeholder {
  color: var(--text-muted);
}
.header-search .search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
  font-size: 0.9rem;
}

/* Nav Links */
.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
}
.nav-links a {
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  font-size: 0.875rem;
  font-weight: 500;
  transition: all var(--transition-fast);
}
.nav-links a:hover, .nav-links a.active {
  color: var(--text-primary);
  background: rgba(108, 92, 231, 0.1);
}

/* Mobile Menu Toggle */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 4px;
}

/* ===== HERO SECTION ===== */
.hero {
  padding: 80px 24px 60px;
  text-align: center;
  max-width: var(--max-width);
  margin: 0 auto;
}
.hero h1 {
  font-size: 2.75rem;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 16px;
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero p {
  font-size: 1.15rem;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto 32px;
}

.hero-search {
  max-width: 560px;
  margin: 0 auto;
  position: relative;
}
.hero-search input {
  width: 100%;
  padding: 16px 24px 16px 52px;
  background: var(--bg-card);
  border: 2px solid var(--border-color);
  border-radius: var(--radius-xl);
  color: var(--text-primary);
  font-size: 1.05rem;
  font-family: var(--font-main);
  outline: none;
  transition: all var(--transition-normal);
}
.hero-search input:focus {
  border-color: var(--accent-primary);
  box-shadow: var(--shadow-glow);
}
.hero-search .search-icon {
  position: absolute;
  left: 18px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 1.2rem;
}
.hero-search .search-shortcut {
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 2px 8px;
  font-size: 0.75rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

/* ===== CATEGORIES ===== */
.categories {
  max-width: var(--max-width);
  margin: 0 auto 40px;
  padding: 0 24px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
}
.category-chip {
  padding: 6px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xl);
  color: var(--text-secondary);
  font-size: 0.85rem;
  cursor: pointer;
  transition: all var(--transition-fast);
}
.category-chip:hover, .category-chip.active {
  background: var(--accent-primary);
  border-color: var(--accent-primary);
  color: #fff;
}

/* ===== TOOLS GRID ===== */
.tools-section {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px 80px;
}
.section-title {
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 24px;
  color: var(--text-primary);
}

.tools-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}

.tool-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 24px;
  transition: all var(--transition-normal);
  cursor: pointer;
  text-decoration: none;
  display: block;
  color: inherit;
}
.tool-card:hover {
  border-color: var(--accent-primary);
  background: var(--bg-card-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-glow);
  color: inherit;
}
.tool-card-icon {
  width: 48px;
  height: 48px;
  background: rgba(108, 92, 231, 0.15);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 16px;
}
.tool-card h3 {
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text-primary);
}
.tool-card p {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.5;
}
.tool-card .tool-tag {
  display: inline-block;
  margin-top: 12px;
  padding: 2px 10px;
  background: rgba(108, 92, 231, 0.1);
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  color: var(--accent-secondary);
}

/* No results */
.no-results {
  text-align: center;
  padding: 60px 24px;
  color: var(--text-muted);
}
.no-results .icon {
  font-size: 3rem;
  margin-bottom: 16px;
}
.no-results h3 {
  font-size: 1.2rem;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

/* ===== TOOL PAGE LAYOUT ===== */
.tool-page {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 40px 24px 80px;
}
.tool-page-header {
  margin-bottom: 32px;
}
.tool-breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 16px;
}
.tool-breadcrumb a {
  color: var(--text-secondary);
}
.tool-breadcrumb a:hover {
  color: var(--accent-secondary);
}
.tool-page-header h1 {
  font-size: 2rem;
  font-weight: 800;
  margin-bottom: 8px;
}
.tool-page-header p {
  color: var(--text-secondary);
  font-size: 1rem;
  max-width: 700px;
}

/* Tool Container */
.tool-container {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 32px;
}

/* Form Elements */
.form-group {
  margin-bottom: 20px;
}
.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.form-control {
  width: 100%;
  padding: 12px 16px;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 0.95rem;
  font-family: var(--font-main);
  outline: none;
  transition: all var(--transition-fast);
}
.form-control:focus {
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px var(--accent-glow);
}
textarea.form-control {
  resize: vertical;
  min-height: 120px;
  font-family: var(--font-mono);
  font-size: 0.875rem;
  line-height: 1.6;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 20px;
  border: none;
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  font-weight: 600;
  font-family: var(--font-main);
  cursor: pointer;
  transition: all var(--transition-fast);
  text-decoration: none;
}
.btn-primary {
  background: var(--accent-gradient);
  color: #fff;
}
.btn-primary:hover {
  box-shadow: var(--shadow-glow);
  transform: translateY(-1px);
}
.btn-secondary {
  background: var(--bg-input);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}
.btn-secondary:hover {
  border-color: var(--accent-primary);
  background: var(--bg-card-hover);
}
.btn-sm {
  padding: 6px 12px;
  font-size: 0.8rem;
}
.btn-lg {
  padding: 14px 28px;
  font-size: 1rem;
}
.btn-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

/* Output Area */
.output-area {
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 16px;
  min-height: 80px;
  font-family: var(--font-mono);
  font-size: 0.875rem;
  line-height: 1.6;
  color: var(--text-primary);
  word-break: break-all;
  white-space: pre-wrap;
  position: relative;
}
.output-area:empty::before {
  content: attr(data-placeholder);
  color: var(--text-muted);
}
.output-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.output-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.copy-btn {
  padding: 4px 10px;
  background: rgba(108, 92, 231, 0.15);
  border: none;
  border-radius: var(--radius-sm);
  color: var(--accent-secondary);
  font-size: 0.75rem;
  cursor: pointer;
  font-family: var(--font-main);
  transition: all var(--transition-fast);
}
.copy-btn:hover {
  background: var(--accent-primary);
  color: #fff;
}

/* Toggle / Switch */
.toggle-group {
  display: flex;
  gap: 4px;
  background: var(--bg-input);
  border-radius: var(--radius-md);
  padding: 4px;
  border: 1px solid var(--border-color);
}
.toggle-btn {
  padding: 6px 16px;
  background: none;
  border: none;
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  font-size: 0.85rem;
  font-family: var(--font-main);
  cursor: pointer;
  transition: all var(--transition-fast);
}
.toggle-btn.active {
  background: var(--accent-primary);
  color: #fff;
}

/* ===== FOOTER ===== */
.footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  padding: 40px 24px;
}
.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 40px;
}
.footer-brand p {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-top: 8px;
  line-height: 1.6;
}
.footer h4 {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 12px;
}
.footer-links {
  list-style: none;
}
.footer-links li {
  margin-bottom: 6px;
}
.footer-links a {
  color: var(--text-muted);
  font-size: 0.85rem;
}
.footer-links a:hover {
  color: var(--accent-secondary);
}
.footer-bottom {
  max-width: var(--max-width);
  margin: 24px auto 0;
  padding-top: 24px;
  border-top: 1px solid var(--border-color);
  text-align: center;
  color: var(--text-muted);
  font-size: 0.8rem;
}

/* ===== COOKIE BANNER ===== */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 9999;
  background: var(--bg-card);
  border-top: 1px solid var(--border-color);
  padding: 20px 24px;
  transform: translateY(100%);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  backdrop-filter: blur(20px);
}
.cookie-banner.visible {
  transform: translateY(0);
}
.cookie-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}
.cookie-text {
  flex: 1;
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.5;
}
.cookie-text a {
  color: var(--accent-secondary);
  text-decoration: underline;
}
.cookie-actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

/* Cookie Settings Modal */
.cookie-modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  z-index: 10001;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.cookie-modal-overlay.open {
  opacity: 1;
  pointer-events: auto;
}
.cookie-modal {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 560px;
  max-height: 85vh;
  overflow-y: auto;
  padding: 32px;
  transform: translateY(30px) scale(0.95);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}
.cookie-modal-overlay.open .cookie-modal {
  transform: translateY(0) scale(1);
}
.cookie-modal h2 {
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--text-primary);
}
.cookie-modal > p {
  font-size: 0.875rem;
  color: var(--text-secondary);
  margin-bottom: 24px;
  line-height: 1.6;
}
.cookie-category {
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  margin-bottom: 12px;
}
.cookie-category-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.cookie-category-info {
  flex: 1;
}
.cookie-category-info h3 {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}
.cookie-category-info p {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.5;
}
.cookie-category.disabled .cookie-category-info h3,
.cookie-category.disabled .cookie-category-info p {
  color: var(--text-muted);
}

/* Toggle Switch */
.cookie-switch {
  position: relative;
  display: inline-block;
  width: 48px;
  height: 26px;
  flex-shrink: 0;
}
.cookie-switch input {
  opacity: 0;
  width: 0;
  height: 0;
  position: absolute;
}
.cookie-switch .slider {
  position: absolute;
  cursor: pointer;
  top: 0; left: 0; right: 0; bottom: 0;
  background-color: var(--border-color);
  border-radius: 26px;
  transition: all 0.3s ease;
}
.cookie-switch .slider::before {
  content: "";
  position: absolute;
  height: 20px;
  width: 20px;
  left: 3px;
  bottom: 3px;
  background-color: #fff;
  border-radius: 50%;
  transition: all 0.3s ease;
}
.cookie-switch input:checked + .slider {
  background-color: var(--accent-primary);
}
.cookie-switch input:checked + .slider::before {
  transform: translateX(22px);
}
.cookie-switch input:disabled + .slider {
  opacity: 0.5;
  cursor: not-allowed;
}
.cookie-switch input:focus-visible + .slider {
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.cookie-modal-actions {
  display: flex;
  gap: 12px;
  margin-top: 24px;
  justify-content: flex-end;
  flex-wrap: wrap;
}
.cookie-modal-actions .btn {
  flex: 1;
  min-width: 140px;
}
.cookie-legend {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-align: center;
  margin-top: 12px;
}
.cookie-legend a {
  color: var(--accent-secondary);
}

/* Floating settings button (after consent) */
.cookie-settings-btn {
  position: fixed;
  bottom: 24px;
  left: 24px;
  z-index: 9990;
  width: 44px;
  height: 44px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1.2rem;
  color: var(--text-secondary);
  transition: all var(--transition-normal);
 box-shadow: var(--shadow-md);
}
.cookie-settings-btn:hover {
  border-color: var(--accent-primary);
  color: var(--accent-secondary);
  transform: scale(1.1);
}

/* ===== ADBLOCK WARNING ===== */
.adblock-warning {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 10000;
  background: rgba(10, 10, 15, 0.95);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 24px;
}
.adblock-content {
  max-width: 500px;
}
.adblock-content .icon {
  font-size: 4rem;
  margin-bottom: 20px;
}
.adblock-content h2 {
  font-size: 1.5rem;
  margin-bottom: 12px;
  color: var(--warning);
}
.adblock-content p {
  color: var(--text-secondary);
  margin-bottom: 24px;
  line-height: 1.6;
}

/* ===== TOAST NOTIFICATION ===== */
.toast-container {
  position: fixed;
  top: 80px;
  right: 24px;
  z-index: 9998;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.toast {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 12px 20px;
  font-size: 0.875rem;
  color: var(--text-primary);
  box-shadow: var(--shadow-lg);
  animation: toastIn 0.3s ease, toastOut 0.3s ease 2.7s forwards;
  display: flex;
  align-items: center;
  gap: 8px;
}
.toast.success { border-left: 3px solid var(--success); }
.toast.error { border-left: 3px solid var(--danger); }
.toast.info { border-left: 3px solid var(--info); }

@keyframes toastIn {
  from { opacity: 0; transform: translateX(100%); }
  to { opacity: 1; transform: translateX(0); }
}
@keyframes toastOut {
  from { opacity: 1; transform: translateX(0); }
  to { opacity: 0; transform: translateX(100%); }
}

/* ===== UTILITY CLASSES ===== */
.text-center { text-align: center; }
.text-accent { color: var(--accent-secondary); }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mt-4 { margin-top: 32px; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }
.hidden { display: none !important; }
.mono { font-family: var(--font-mono); }

/* Stats Row */
.stats-row {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.stat-item {
  flex: 1;
  min-width: 100px;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  text-align: center;
}
.stat-item .stat-value {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent-secondary);
}
.stat-item .stat-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Color Preview */
.color-preview {
  width: 100%;
  height: 80px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  transition: background-color var(--transition-fast);
}

/* QR Code output */
#qr-output canvas, #qr-output img {
  border-radius: var(--radius-md);
}

/* Markdown Preview */
.md-preview {
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 20px;
  min-height: 200px;
  line-height: 1.7;
}
.md-preview h1, .md-preview h2, .md-preview h3 {
  margin: 16px 0 8px;
  color: var(--text-primary);
}
.md-preview h1 { font-size: 1.6rem; }
.md-preview h2 { font-size: 1.3rem; }
.md-preview h3 { font-size: 1.1rem; }
.md-preview p { margin-bottom: 12px; }
.md-preview code {
  background: rgba(108, 92, 231, 0.15);
  padding: 2px 6px;
  border-radius: 4px;
  font-family: var(--font-mono);
  font-size: 0.85em;
}
.md-preview pre {
  background: var(--bg-secondary);
  padding: 16px;
  border-radius: var(--radius-md);
  overflow-x: auto;
  margin: 12px 0;
}
.md-preview pre code {
  background: none;
  padding: 0;
}
.md-preview ul, .md-preview ol {
  margin: 8px 0 12px 24px;
}
.md-preview blockquote {
  border-left: 3px solid var(--accent-primary);
  padding-left: 16px;
  color: var(--text-secondary);
  margin: 12px 0;
}
.md-preview a {
  color: var(--accent-secondary);
}
.md-preview img {
  max-width: 100%;
  border-radius: var(--radius-sm);
}

/* Diff output */
.diff-line {
  padding: 2px 12px;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  line-height: 1.6;
}
.diff-added { background: rgba(0, 206, 201, 0.1); color: var(--success); }
.diff-removed { background: rgba(255, 118, 117, 0.1); color: var(--danger); }
.diff-unchanged { color: var(--text-muted); }

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .hero h1 { font-size: 1.8rem; }
  .hero p { font-size: 1rem; }
  .header-search { display: none; }
  .nav-links { display: none; }
  .menu-toggle { display: block; }
  .footer-inner {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .tools-grid {
    grid-template-columns: 1fr;
  }
  .cookie-inner {
    flex-direction: column;
    text-align: center;
  }
  .tool-page-header h1 { font-size: 1.5rem; }
  .tool-container { padding: 20px; }
  .stats-row { flex-direction: column; }
}
@media (max-width: 480px) {
  .hero { padding: 48px 16px 40px; }
  .hero h1 { font-size: 1.5rem; }
  .tools-section { padding: 0 16px 60px; }
  .tool-container { padding: 16px; }
}
