/* Shell components: header, nav, drawer, footer, 404. Blog-layer components live in pages.css. */

/* ---------- Header ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(249, 248, 244, .92); border-bottom: 1px solid var(--line); backdrop-filter: saturate(1.2) blur(10px); -webkit-backdrop-filter: saturate(1.2) blur(10px); }
.site-header .wrap { display: flex; align-items: center; height: 73px; gap: 24px; }
.brand { display: inline-flex; align-items: center; margin-right: auto; }
.brand img { height: 35px; width: auto; }
.footer__brand .brand img { height: 32px; }
.nav { display: flex; align-items: center; gap: 24px; }
.nav__item { position: relative; }
.nav__link {
  display: inline-flex; align-items: center; gap: 5px; padding: 8px 0; background: none; border: 0; cursor: pointer;
  font: 400 14px/1 var(--sans); color: var(--ink-2); transition: color .2s ease;
}
.nav__link:hover, .nav__item.is-open > .nav__link { color: var(--ink); }
.nav__link .icon { width: 12px; height: 12px; transition: transform .2s ease; }
.nav__item.is-open > .nav__link .icon { transform: rotate(180deg); }
.nav__menu {
  position: absolute; top: calc(100% + 12px); left: -18px; min-width: 232px; padding: 10px;
  background: #fffdf8; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-card);
  opacity: 0; visibility: hidden; transform: translateY(-4px); transition: opacity .18s ease, transform .18s ease, visibility .18s;
}
.nav__menu::before { content: ""; position: absolute; left: 0; right: 0; top: -14px; height: 14px; }
.nav__item.is-open > .nav__menu { opacity: 1; visibility: visible; transform: none; }
.nav__menu a { display: block; padding: 9px 12px; border-radius: 8px; font-size: 14px; line-height: 1.35; color: var(--ink-2); }
.nav__menu a:hover { background: var(--band); color: var(--ink); }
.header-actions { display: flex; align-items: center; gap: 10px; margin-left: 6px; padding-left: 22px; border-left: 1px solid var(--line-2); }
.menu-toggle { display: none; width: 44px; height: 44px; border-radius: 999px; border: 1px solid var(--line-2); background: #fff; place-items: center; cursor: pointer; }
.menu-toggle .icon { width: 20px; height: 20px; }

/* ---------- Mobile drawer ---------- */
.drawer { position: fixed; inset: 0; z-index: 90; visibility: hidden; }
.drawer.is-open { visibility: visible; }
.drawer__scrim { position: absolute; inset: 0; background: rgba(11, 15, 20, .45); opacity: 0; transition: opacity .25s ease; }
.drawer.is-open .drawer__scrim { opacity: 1; }
.drawer__panel {
  position: absolute; inset: 0 0 0 auto; width: min(360px, 88vw); background: var(--bg); padding: 20px 22px 32px;
  overflow-y: auto; transform: translateX(100%); transition: transform .28s ease; box-shadow: -20px 0 40px -20px rgba(0, 0, 0, .3);
}
.drawer.is-open .drawer__panel { transform: none; }
.drawer__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.drawer__close { width: 40px; height: 40px; border-radius: 999px; border: 1px solid var(--line-2); background: #fff; display: grid; place-items: center; cursor: pointer; }
.drawer__close .icon { width: 18px; height: 18px; }
.drawer__group { border-top: 1px solid var(--line); padding: 14px 0 10px; }
.drawer__title { font: 500 9.5px/1 var(--mono); letter-spacing: .22em; text-transform: uppercase; color: var(--gold-ink); margin-bottom: 8px; }
.drawer__group a { display: block; padding: 8px 0; font-size: 15px; color: var(--ink-2); }
.drawer__actions { display: grid; gap: 10px; margin: 6px 0 18px; }
.drawer__actions .btn { width: 100%; }

/* ---------- Blog bar ---------- */

/* ---------- Footer ---------- */
.footer { background: var(--bg); padding-top: 48px; border-top: 1px solid var(--line); }
.footer__grid { display: grid; grid-template-columns: 1.45fr 1fr 1fr 1fr; gap: 0; }
.footer__grid > * + * { padding-left: 36px; border-left: 1px solid var(--line); }
.footer__about { margin-top: 12px; font-size: 15px; line-height: 1.45; color: var(--ink-2); white-space: nowrap; }
.footer__head { font: 400 22px/1.2 var(--serif); letter-spacing: -.01em; color: var(--ink); margin-bottom: 12px; padding-bottom: 10px; position: relative; }
.footer__head::after { content: ""; position: absolute; left: 0; bottom: 0; width: 32px; height: 1.5px; background: var(--gold); }
.footer__links a { display: block; padding: 3px 0; font-size: 14.5px; line-height: 1.45; color: var(--ink-2); transition: color .2s ease; }
.footer__links a:hover { color: var(--ink); }
.footer__contact { margin-top: 16px; font-size: 14.5px; line-height: 1.6; color: var(--ink-2); }
.footer__line { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: 12px; align-items: start; }
.footer__line + .footer__line { margin-top: 8px; }
.footer__line .icon { width: 18px; height: 18px; margin-top: 3px; color: var(--gold-ink); }
.footer__line strong { display: block; font-weight: 600; color: var(--ink); }
.footer__contact a { overflow-wrap: anywhere; }
.footer__contact a:hover { color: var(--ink); }
.footer__connect { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 20px 40px; margin-top: 32px; padding-block: 18px; border-block: 1px solid var(--line); }
.footer__follow, .footer__download { display: flex; align-items: center; flex-wrap: wrap; gap: 14px 28px; }
.footer__subhead { font: 400 18px/1.2 var(--serif); color: var(--ink); }
.social { display: flex; gap: 10px; }
.social a { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; background: #c9a96a; color: #fff; transition: background-color .2s ease, transform .2s ease; }
.social a:hover { background: #a98a4c; transform: translateY(-1px); }
.social .icon { width: 18px; height: 18px; }
.social__link--linkedin .icon { width: 25px; height: 25px; }
.social__link--youtube .icon { width: 23px; height: 23px; }
.social__link--instagram .icon { width: 24px; height: 24px; stroke-width: 1.8; }
.social__link--facebook .icon { width: 20px; height: 20px; }
.apps { display: flex; flex-wrap: wrap; gap: 10px; }
.app-badge { display: inline-flex; align-items: center; gap: 10px; height: 48px; padding: 0 18px 0 14px; border-radius: 10px; background: #d8c08a; color: #2a1f08; border: 1px solid rgba(150, 112, 28, .25); transition: background-color .2s ease; }
.app-badge:hover { background: #ceb47a; }
.app-badge .icon { width: 22px; height: 22px; }
.app-badge span { display: flex; flex-direction: column; font: 600 16px/1.1 var(--sans); }
.app-badge small { font: 500 10px/1.2 var(--sans); letter-spacing: .02em; text-transform: uppercase; }
.footer__legal { padding: 0 0 56px; text-align: center; font-size: 13.5px; line-height: 1.6; color: var(--ink-2); }
.footer__legal > * { padding-block: 16px; }
.footer__legal > * + * { border-top: 1px solid var(--line); }
.footer__legal-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 0; }
.footer__legal-links a { font-size: 12.5px; color: var(--ink-2); }
.footer__legal-links a:hover { color: var(--ink); }
.footer__legal-links a + a::before { content: "\2022"; margin: 0 6px; color: var(--gold); }
.footer__reg { font-size: 16px; line-height: 1.6; color: var(--ink); }
.footer__reg span { margin: 0 6px; color: var(--gold); }
.footer__office { margin-top: 8px; }
.footer__disclaimer { max-width: 1040px; margin: 8px auto 0; }
.footer__disclaimer a { color: var(--gold-ink); text-decoration: underline; text-underline-offset: 3px; }
.footer__copy { margin-top: 0; color: var(--muted); }

/* ---------- Disclaimer (posts) and 404 ---------- */
.disclaimer { margin-top: 40px; padding: 16px 20px; border: 1px solid var(--line-2); border-radius: var(--radius); background: var(--card); font-size: 13.5px; line-height: 1.6; color: var(--ink-2); }
.not-found { min-height: 46vh; }
.not-found .lead { margin-top: 22px; }
.not-found__cta { margin-top: 30px; }

/* ---------- Responsive ---------- */
@media (min-width: 1025px) {
  .footer__grid { grid-template-columns: minmax(0, 1.15fr) repeat(3, minmax(0, .9fr)); }
  .footer__grid > * + * { padding-left: 32px; }
}
@media (max-width: 1180px) { .nav { gap: 18px; } }
@media (max-width: 1024px) {
  .nav, .header-actions .btn { display: none; }
  .header-actions { border-left: 0; padding-left: 0; }
  .menu-toggle { display: grid; }
  .footer__grid { grid-template-columns: 1fr 1fr 1fr; row-gap: 24px; }
  .footer__brand { grid-column: 1 / -1; }
  .footer__grid > .footer__links:nth-of-type(1) { padding-left: 0; border-left: 0; }
}
@media (max-width: 720px) {
  body { font-size: 16px; }
  .brand img { height: 30px; }
  .site-header .wrap { height: 64px; }
  html { scroll-padding-top: 76px; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .footer__grid > * + * { padding-left: 20px; }
  .footer__grid > .footer__links:nth-of-type(3) { padding-left: 0; border-left: 0; }
  .footer__connect { flex-direction: column; align-items: flex-start; }
  .footer__legal-links { gap: 6px 16px; }
  .footer__legal-links a + a::before { display: none; }
}
@media (max-width: 420px) { .footer__about { white-space: normal; } }
