/* Общие стили страниц-калькуляторов и справочных страниц EasyFood.
   Один файл на все страницы: иначе к двухсотой продуктовой странице
   получится двести копий одного и того же CSS. */

:root {
  --accent: #DFA03B;
  --light: #B7CD8D;
  --text-main: #F7F9F5;
  --text-muted: rgba(247, 249, 245, 0.78);
  --radius-xl: 32px;
  --radius-pill: 999px;
}
* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", system-ui, sans-serif;
  background: radial-gradient(circle at top left, rgba(223, 160, 59, 0.34) 0, transparent 55%),
    radial-gradient(circle at bottom right, rgba(49, 86, 77, 0.7) 0, transparent 60%), #111517;
  color: var(--text-main);
  min-height: 100vh;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
body::before {
  content: ""; position: fixed; inset: -25%;
  background: radial-gradient(circle at 15% 15%, rgba(223, 160, 59, 0.45) 0, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(183, 205, 141, 0.35) 0, transparent 45%),
    radial-gradient(circle at 10% 80%, rgba(49, 86, 77, 0.8) 0, transparent 55%);
  filter: blur(4px); z-index: -2;
}
body::after {
  content: ""; position: fixed; inset: 0;
  background: radial-gradient(circle at top, rgba(255, 255, 255, 0.04) 0, transparent 55%);
  backdrop-filter: blur(34px); z-index: -1;
}

.wrap { width: 100%; max-width: 860px; margin: 0 auto; padding: 28px clamp(16px, 4vw, 32px) 72px; }

.site-head { display: flex; align-items: center; gap: 12px; margin-bottom: 36px; }
.site-head img { width: 40px; height: 40px; border-radius: 50%; box-shadow: 0 0 20px rgba(223,160,59,.45); }
.site-head a { color: inherit; text-decoration: none; display: flex; align-items: center; gap: 12px; }
.site-head .nm { font-weight: 650; font-size: 17px; letter-spacing: .02em; }
.site-head .sub { font-size: 12px; color: var(--text-muted); }

.crumbs { font-size: 13px; color: var(--text-muted); margin-bottom: 18px; }
.crumbs a { color: var(--text-muted); text-decoration: none; }
.crumbs a:hover { color: var(--accent); }

h1 { font-size: clamp(28px, 5vw, 40px); font-weight: 680; line-height: 1.15; margin-bottom: 14px; }
h1 span { background-image: linear-gradient(120deg, #FFE9C4, #DFA03B); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lead { font-size: 16px; color: var(--text-muted); margin-bottom: 30px; max-width: 640px; }

.card {
  background: rgba(9, 23, 20, 0.55); border: 1px solid rgba(255,255,255,.08);
  border-radius: var(--radius-xl); backdrop-filter: blur(20px);
  padding: clamp(20px, 4vw, 32px); margin-bottom: 26px;
}

.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 16px; }
.field { display: flex; flex-direction: column; gap: 7px; }
.field label { font-size: 13px; color: var(--text-muted); }
.field input, .field select {
  width: 100%; padding: 13px 15px; border-radius: 14px;
  border: 1px solid rgba(255,255,255,.15); background: rgba(0,0,0,.4);
  color: var(--text-main); font-size: 16px; font-family: inherit; outline: none;
  transition: border-color .2s;
}
.field input:focus, .field select:focus { border-color: var(--accent); }
.field select option { background: #111517; color: var(--text-main); }

.seg { display: flex; gap: 8px; }
.seg button {
  flex: 1; padding: 13px 8px; border-radius: 14px; cursor: pointer; font-size: 15px;
  font-family: inherit; border: 1px solid rgba(255,255,255,.15);
  background: rgba(0,0,0,.4); color: var(--text-muted); transition: all .2s;
}
.seg button[aria-pressed="true"] { background: rgba(223,160,59,.16); border-color: var(--accent); color: #FFE9C4; font-weight: 600; }

.btn-calc {
  width: 100%; margin-top: 22px; padding: 16px; border: none; cursor: pointer;
  border-radius: var(--radius-pill); font-size: 16px; font-weight: 650; font-family: inherit;
  background: linear-gradient(135deg, #FFE9C4, #DFA03B); color: #102721;
}
.btn-calc:hover { transform: translateY(-1px); }

.err { color: #ff9b9b; font-size: 14px; margin-top: 12px; display: none; }

.result { display: none; }
.kcal-big { text-align: center; padding: 6px 0 20px; }
.kcal-big .num { font-size: clamp(46px, 10vw, 68px); font-weight: 700; color: var(--accent); line-height: 1; }
.kcal-big .cap { font-size: 15px; color: var(--text-muted); margin-top: 8px; }

.macros { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 18px; }
.macro { text-align: center; padding: 16px 8px; border-radius: 16px; background: rgba(6,16,14,.6); border: 1px solid rgba(255,255,255,.07); }
.macro b { display: block; font-size: 22px; font-weight: 650; color: #FFE9C4; }
.macro span { font-size: 12px; color: var(--text-muted); }

.facts { display: flex; flex-wrap: wrap; gap: 10px; }
.fact { flex: 1 1 200px; padding: 13px 16px; border-radius: 14px; background: rgba(6,16,14,.5); border: 1px solid rgba(255,255,255,.06); font-size: 14px; color: var(--text-muted); }
.fact b { color: var(--text-main); font-weight: 600; }

.cta { margin-top: 22px; padding-top: 22px; border-top: 1px solid rgba(255,255,255,.08); text-align: center; }
.cta p { font-size: 15px; color: var(--text-muted); margin-bottom: 14px; }
.btn-store {
  display: inline-flex; align-items: center; gap: 9px; padding: 14px 26px; border-radius: var(--radius-pill);
  background: linear-gradient(135deg, #FFE9C4, #DFA03B); color: #102721;
  text-decoration: none; font-weight: 650; font-size: 15px;
}

.prose h2 { font-size: clamp(21px, 3.4vw, 27px); font-weight: 650; margin: 30px 0 12px; }
.prose h3 { font-size: 17px; font-weight: 620; margin: 22px 0 8px; color: #FFE9C4; }
.prose p { color: var(--text-muted); margin-bottom: 12px; }
.prose ul { color: var(--text-muted); margin: 0 0 14px 20px; }
.prose li { margin-bottom: 6px; }
.prose table { width: 100%; border-collapse: collapse; margin: 8px 0 16px; font-size: 15px; }
.prose th, .prose td { text-align: left; padding: 10px 12px; border-bottom: 1px solid rgba(255,255,255,.08); color: var(--text-muted); }
.prose th { color: var(--text-main); font-weight: 600; }
.prose tr.hl td { color: #FFE9C4; font-weight: 600; }
.prose code { background: rgba(0,0,0,.4); padding: 2px 7px; border-radius: 6px; font-size: 14px; color: #FFE9C4; }
.note { font-size: 13px; color: rgba(247,249,245,.55); border-left: 2px solid rgba(223,160,59,.5); padding-left: 14px; margin: 18px 0; }

/* Перелинковка между калькуляторами: и человеку удобнее, и поисковик
   лучше обходит раздел, когда страницы ссылаются друг на друга. */
.more { margin-top: 36px; }
.more h2 { font-size: 20px; font-weight: 650; margin-bottom: 14px; }
.more-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.more-grid a {
  display: block; padding: 15px 18px; border-radius: 16px; text-decoration: none;
  background: rgba(9,23,20,.5); border: 1px solid rgba(255,255,255,.07);
  color: var(--text-main); font-size: 15px; font-weight: 600; transition: all .2s;
}
.more-grid a:hover { border-color: rgba(223,160,59,.5); background: rgba(15,35,30,.6); }
.more-grid a span { display: block; font-size: 12.5px; font-weight: 400; color: var(--text-muted); margin-top: 3px; }

.foot { margin-top: 44px; padding-top: 22px; border-top: 1px solid rgba(255,255,255,.08); font-size: 13px; color: rgba(247,249,245,.55); display: flex; flex-wrap: wrap; gap: 16px; justify-content: space-between; }
.foot a { color: rgba(247,249,245,.7); text-decoration: none; }
.foot a:hover { color: var(--accent); }
a { color: var(--accent); }
