/* 4DUK — Радио Чипльдук Edition — единый файл стилей */

:root {
  --chip-bg: #f0f0f0;
  --chip-text: #222;
  --accent: #d43a0f;
  --panel: #ffffff;
  --border: #ccc;
  --dark: #1a1a1a;
}

body { background: var(--chip-bg); color: var(--chip-text); font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif; margin: 0; padding: 0; }
header { padding: 1.2rem 1rem; border-bottom: 2px solid var(--accent); background: var(--panel); }
h1 { margin: 0 0 0.3rem 0; font-size: 1.8rem; line-height: 1.1; }
h2 { border-left: 5px solid var(--accent); padding-left: 12px; margin: 1.2rem 0 0.6rem 0; font-size: 1.4rem; }
h3 { margin: 0 0 0.5rem 0; font-size: 1.1rem; }
.subtitle { margin: 0; font-size: 0.95rem; color: #555; font-style: italic; }
main { max-width: 960px; margin: 1.5rem auto; padding: 0 1rem; }
section { margin-bottom: 3rem; }
p { line-height: 1.6; }
ul, ol { line-height: 1.8; }
pre { background: #1e1e1e; color: #fff; padding: 1rem; overflow-x: auto; border-radius: 6px; font-family: monospace; }
code { font-family: monospace; }

.chip-quote { background: #fff; border: 1px solid var(--border); padding: 1rem; border-radius: 6px; margin: 1rem 0; font-weight: 600; color: var(--dark); box-shadow: 0 2px 4px rgba(0,0,0,0.06); border-color: var(--accent); }

.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.2rem; }
.feature-card { background: var(--panel); border: 1px solid var(--border); padding: 1.2rem; border-radius: 8px; box-shadow: 0 2px 6px rgba(0,0,0,0.08); }

.criteria-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.2rem; }
.crit-card { background: var(--panel); border: 1px solid var(--border); padding: 1.2rem; border-radius: 8px; box-shadow: 0 2px 6px rgba(0,0,0,0.08); }

.project-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1.5rem; }
.project-card { background: var(--panel); border: 1px solid var(--border); padding: 1.2rem; border-radius: 8px; box-shadow: 0 2px 6px rgba(0,0,0,0.08); position: relative; overflow: hidden; }
.project-tag { display: inline-block; background: #eee; color: #444; padding: 4px 8px; border-radius: 4px; font-size: 0.85rem; margin-bottom: 0.5rem; }
.tech-list { list-style: none; padding: 0; margin: 0.8rem 0 0 0; font-size: 0.9rem; }
.tech-list li { margin-bottom: 4px; }
.tech-list::before { content: "Технологии: "; font-weight: bold; }

.badge { display: inline-block; background: #eee; color: #444; padding: 4px 8px; border-radius: 4px; font-size: 0.85rem; margin-right: 6px; }

table { width: 100%; border-collapse: collapse; margin: 1rem 0; font-size: 0.92rem; }
th, td { border: 1px solid var(--border); padding: 8px 10px; text-align: left; }
th { background: #fafafa; }

.cta { display: inline-block; background: var(--accent); color: white; padding: 0.7rem 1.2rem; text-decoration: none; border-radius: 4px; font-weight: 600; }

footer { text-align: center; padding: 2rem 1rem; color: #777; font-size: 0.9rem; border-top: 1px solid #ddd; margin-top: 2rem; }

/* Навигация */
.navbar { display: flex; align-items: center; gap: 1rem; padding: 0.8rem 1rem; background: var(--panel); border-bottom: 1px solid var(--border); flex-wrap: wrap; position: sticky; top: 0; z-index: 1000; }
.nav-brand { font-weight: bold; color: #000; text-decoration: none; white-space: nowrap; }
.nav-menu { display: flex; gap: 0.25rem; flex-grow: 1; justify-content: center; }
.nav-item { position: relative; }
.nav-link { display: block; padding: 0.6rem 0.9rem; text-decoration: none; color: var(--chip-text); font-weight: 500; border-radius: 4px; }
.nav-link:hover { background: #f5f5f5; }
.dropdown-menu { position: absolute; left: 0; background: var(--panel); border: 1px solid var(--border); box-shadow: 0 4px 12px rgba(0,0,0,0.12); display: none; flex-direction: column; min-width: 220px; z-index: 999; border-radius: 6px; overflow: hidden; }
.bdropdown-menu { position: absolute; top: calc(100% + 0.5rem); left: 0; background: var(--panel); border: 1px solid var(--border); box-shadow: 0 4px 12px rgba(0,0,0,0.12); display: none; flex-direction: column; min-width: 220px; z-index: 999; border-radius: 6px; overflow: hidden; }
.nav-item:hover .dropdown-menu { display: flex; }
.dropdown-item { display: block; padding: 0.7rem 1rem; text-decoration: none; color: var(--chip-text); }
.dropdown-item:hover { background: #fff5f0; color: var(--accent); }
.burger { display: none; cursor: pointer; font-size: 1.3rem; background: none; border: none; color: var(--chip-text); }

@media (max-width: 768px) {
  .burger { display: block; }
  .nav-menu { flex-direction: column; display: none; width: 100%; margin-top: 0.5rem; border-top: 1px solid var(--border); padding-top: 0.5rem; }
  .nav-menu.active { display: flex; }
  .dropdown-menu { position: static; display: none; flex-direction: column; min-width: auto; box-shadow: none; border: none; background: transparent; }
  .nav-item.mobile-open .dropdown-menu { display: flex; }
  .nav-item:hover .dropdown-menu { display: none; }
}
