@import url("https://fonts.googleapis.com/css2?family=Noto+Sans+Georgian:wght@400;500;600;700&display=swap");
:root {
  --paper: #faf6ed;
  --ink: #3c4d46;
  --red: #9d4b42;
  --line: #ded8c9;
  --muted: #7a7d6b;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Georgia, "DejaVu Serif", serif;
  line-height: 1.8;
}
body:before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.13;
  z-index: 10;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Cpath fill='%23887755' filter='url(%23n)' opacity='.35' d='M0 0h180v180H0z'/%3E%3C/svg%3E");
}
button,
a,
input {
  font: inherit;
}
button,
a {
  -webkit-tap-highlight-color: transparent;
}
button {
  color: inherit;
  cursor: pointer;
}
button:focus-visible,
a:focus-visible {
  outline: 3px solid #b7764a;
  outline-offset: 5px;
}
header {
  max-width: 1300px;
  margin: auto;
  padding: 28px 45px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.brand {
  border: 0;
  background: none;
  display: flex;
  gap: 12px;
  align-items: center;
  text-align: left;
  line-height: 1.55;
  font-size: 15px;
}
.brand b {
  color: var(--red);
  font-size: 19px;
}
.sun {
  font-family: serif;
  font-size: 48px;
  color: #c3924e;
  line-height: 1;
}
.header-note {
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.6px;
}
.search {
  border: 1px solid var(--line);
  border-radius: 30px;
  background: transparent;
  padding: 6px 18px;
  font-size: 14px;
}
nav {
  max-width: 1170px;
  margin: 14px auto 0;
  display: flex;
  justify-content: space-between;
  gap: 8px;
  padding: 0 26px;
}
.cloud {
  position: relative;
  isolation: isolate;
  flex: 1;
  border: 0;
  background: none;
  min-width: 100px;
  height: 94px;
  font-size: 15px;
  font-weight: bold;
  transition: transform 0.2s;
}
.cloud:nth-child(even) {
  margin-top: 12px;
}
.cloud svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  overflow: visible;
}
.cloud path {
  stroke: #fffdf8;
  stroke-width: 2.5;
  transition: stroke 0.2s;
}
.cloud:hover {
  transform: translateY(-5px) rotate(-2deg);
}
.cloud.active path {
  stroke: #9a8062;
  stroke-width: 1.4;
  stroke-dasharray: 3 3;
}
.cloud small {
  display: block;
  font-size: 10px;
  font-weight: normal;
  opacity: 0.65;
  line-height: 1.1;
}
main {
  min-height: 65vh;
}
.hero {
  max-width: 1100px;
  margin: 38px auto 0;
  text-align: center;
  padding: 0 24px;
}
.eyebrow {
  font-size: 12px;
  color: #9b7c52;
  letter-spacing: 1.2px;
  margin-bottom: 16px;
}
.hero h1 {
  font-weight: normal;
  color: var(--red);
  font-size: clamp(30px, 4vw, 51px);
  margin: 0 0 14px;
  line-height: 1.7;
}
.hero h1 span {
  display: inline-block;
  border-bottom: 2px solid #d8bd87;
  transform: rotate(-1deg);
}
.hero p {
  max-width: 630px;
  margin: 0 auto;
  font-size: 15px;
  color: #737766;
}
.hero-art {
  display: block;
  width: 660px;
  max-width: 90%;
  margin: 28px auto 18px;
  mix-blend-mode: multiply;
}
.hero .invite {
  font-size: 13px;
  color: #8c7558;
  margin-top: 3px;
}
.intro-strip {
  max-width: 1060px;
  margin: 48px auto 0;
  padding: 28px 0;
  border-top: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
}
.intro-strip blockquote {
  margin: 0;
  font-size: 17px;
  max-width: 660px;
}
.intro-strip cite {
  display: block;
  font-size: 11px;
  font-style: normal;
  color: var(--muted);
  margin-top: 7px;
}
.text-link {
  border: 0;
  border-bottom: 1px solid #b88a60;
  background: none;
  padding: 4px 0;
  white-space: nowrap;
  color: #99614d;
  font-size: 13px;
}
.explore {
  max-width: 1060px;
  margin: 22px auto 60px;
  padding: 0 24px;
}
.section-label {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: var(--muted);
}
.section-label h2 {
  font-size: 20px;
  font-weight: normal;
  color: var(--ink);
}
.feature {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 46px;
  align-items: center;
  margin-top: 18px;
}
.feature img {
  width: 100%;
  mix-blend-mode: multiply;
}
.feature h3 {
  font-size: 28px;
  font-weight: normal;
  margin: 8px 0;
}
.feature p {
  font-size: 14px;
  color: var(--muted);
}
.tag {
  font-size: 11px;
  letter-spacing: 0.7px;
  color: #a07d4d;
}
.inside {
  max-width: 1240px;
  margin: 40px auto 70px;
  padding: 0 38px;
}
.crumb {
  font-size: 11px;
  color: var(--muted);
  margin: 0 0 25px;
}
.crumb button {
  border: 0;
  background: none;
  padding: 0;
}
.reading-layout {
  display: grid;
  grid-template-columns: 265px minmax(0, 1fr);
  gap: 56px;
}
.sidebar {
  border-right: 1px solid var(--line);
  padding-right: 25px;
}
.sidebar h2 {
  font-size: 22px;
  font-weight: normal;
  color: var(--red);
  margin: 0 0 20px;
}
.sidebar details {
  border-top: 1px solid var(--line);
  padding: 12px 0;
}
.sidebar summary {
  cursor: pointer;
  font-size: 14px;
  list-style: none;
  display: flex;
  justify-content: space-between;
}
.sidebar summary:after {
  content: "+";
  font-size: 19px;
  color: #9b8c6d;
}
.sidebar details[open] summary:after {
  content: "−";
}
.sidebar .item {
  display: block;
  width: 100%;
  border: 0;
  background: none;
  text-align: left;
  font-size: 12px;
  padding: 9px 10px 9px 16px;
  margin-top: 4px;
  color: #7e8072;
  border-radius: 3px;
}
.sidebar .item:hover,
.sidebar .item.selected {
  background: #ececdd;
  color: #56644b;
}
.category-cover {
  text-align: center;
  padding: 8px 15px;
}
.category-cover h1 {
  font-size: 36px;
  color: var(--red);
  font-weight: normal;
  margin: 5px;
}
.category-cover p {
  font-size: 14px;
  max-width: 520px;
  margin: 15px auto;
  color: var(--muted);
}
.category-cover img {
  width: 90%;
  max-width: 650px;
  mix-blend-mode: multiply;
  margin: 20px auto;
}
.category-choices {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}
.article {
  max-width: 750px;
  padding: 0 10px;
}
.article h1 {
  font-size: 36px;
  font-weight: normal;
  color: var(--red);
  margin: 4px 0 10px;
}
.article .deck {
  font-size: 14px;
  color: var(--muted);
}
.article img {
  width: 100%;
  mix-blend-mode: multiply;
  margin: 22px 0;
}
.article p {
  font-size: 16px;
  line-height: 2.2;
  margin: 22px 0;
}
.article .article-top {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}
.font-control button {
  background: none;
  border: 1px solid var(--line);
  padding: 0 9px;
  border-radius: 50%;
  font-size: 12px;
}
.article .byline {
  font-size: 11px;
  color: var(--muted);
}
.article-bottom {
  border-top: 1px solid var(--line);
  margin-top: 35px;
  padding-top: 20px;
}
.menu-toggle {
  display: none;
}
.contact {
  max-width: 650px;
  margin: 60px auto;
  padding: 20px;
  text-align: center;
}
footer {
  border-top: 1px solid var(--line);
  max-width: 1200px;
  margin: auto;
  padding: 22px 35px;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  font-size: 10px;
  color: var(--muted);
}
footer button {
  border: 0;
  background: none;
  font-size: 11px;
}
dialog {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--paper);
  width: 540px;
  max-width: 90%;
  padding: 32px;
  color: var(--ink);
}
dialog::backdrop {
  background: #34433455;
  backdrop-filter: blur(4px);
}
dialog h2 {
  font-weight: normal;
}
dialog input {
  width: 100%;
  padding: 12px;
  border: 1px solid var(--line);
  background: #fffdf7;
  border-radius: 8px;
}
.close {
  float: right;
  border: 0;
  background: none;
  font-size: 24px;
}
#results button {
  display: block;
  background: none;
  border: 0;
  border-bottom: 1px solid var(--line);
  width: 100%;
  text-align: left;
  padding: 14px 0;
}
#results p {
  font-size: 13px;
}
@media (max-width: 800px) {
  header {
    padding: 20px;
  }
  .header-note {
    display: none;
  }
  nav {
    overflow: auto;
    justify-content: flex-start;
    padding: 0 14px;
    gap: 4px;
  }
  .cloud {
    flex: 0 0 120px;
    height: 80px;
    font-size: 13px;
  }
  .hero {
    margin-top: 28px;
  }
  .hero p {
    font-size: 13px;
  }
  .intro-strip {
    margin: 32px 22px 0;
    display: block;
  }
  .intro-strip blockquote {
    font-size: 14px;
  }
  .intro-strip button {
    margin-top: 15px;
  }
  .feature {
    gap: 18px;
    grid-template-columns: 1fr;
  }
  .feature img {
    max-width: 550px;
  }
  .reading-layout {
    grid-template-columns: 1fr;
    gap: 25px;
  }
  .inside {
    padding: 0 22px;
    margin-top: 25px;
  }
  .sidebar {
    display: none;
    border-right: 0;
    padding: 15px;
    background: #f0efe4;
  }
  .sidebar.shown {
    display: block;
  }
  .menu-toggle {
    display: block;
    border: 1px solid var(--line);
    background: none;
    border-radius: 8px;
    padding: 7px 16px;
    margin-bottom: 20px;
    font-size: 13px;
  }
  .article h1,
  .category-cover h1 {
    font-size: 29px;
  }
  .article p {
    font-size: 15px;
  }
  .category-cover {
    padding: 0;
  }
  .category-cover img {
    width: 100%;
  }
  footer {
    padding: 22px;
    display: block;
  }
  .search span {
    display: none;
  }
}

/* მთავარი გვერდის დამატებითი განლაგება */
.hero {
  margin-top: 10px;
}
.hero-art {
  width: 430px;
  mix-blend-mode: normal;
}
.intro-strip {
  flex-direction: column;
  justify-content: center;
  text-align: center;
  padding-left: 20px;
  padding-right: 20px;
}
.intro-strip blockquote {
  max-width: 100%;
  margin: 0 auto;
}
.intro-strip cite {
  text-align: right;
}
footer {
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.article figure {
  margin: 22px 0;
}
.article figure img {
  margin: 0;
}
.article figcaption {
  font-size: 12px;
  text-align: center;
  color: var(--muted);
}
.article h2 {
  font-size: 24px;
  font-weight: normal;
}
.article blockquote {
  border-left: 3px solid #d8bd87;
  margin: 25px 0;
  padding: 0 20px;
}
.article blockquote cite {
  display: block;
  text-align: right;
  font-size: 12px;
}
.error-panel {
  max-width: 700px;
  margin: 60px auto;
  padding: 25px;
}
.error-panel p {
  overflow-wrap: anywhere;
}
.article a {
  color: var(--red);
}

/* ჩასვი style.css-ის ბოლოში. ფონტის ჩასართავად იხილე README.txt. */
body {
  font-family: "Noto Sans Georgian", sans-serif;
}
button,
input {
  font-family: inherit;
}
body:has(#main > .hero) {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
}
body:has(#main > .hero) header {
  width: 100%;
  padding-top: 12px;
  padding-bottom: 4px;
}
body:has(#main > .hero) nav {
  width: 100%;
  margin-top: 0;
}
body:has(#main > .hero) .cloud {
  height: 76px;
}
body:has(#main > .hero) .cloud:nth-child(even) {
  margin-top: 6px;
}
#main:has(> .hero) {
  min-height: 0;
}
.hero {
  margin: 6px auto 0;
  padding: 0 20px;
}
.hero h1 {
  font-size: clamp(24px, 2.7vw, 36px);
  line-height: 1.45;
  margin: 0 0 8px;
  font-weight: 500;
}
.hero .eyebrow {
  margin-bottom: 5px;
}
.hero p {
  font-size: 13px;
  line-height: 1.7;
}
.hero-art {
  display: block;
  height: clamp(170px, calc(100svh - 380px), 360px);
  width: auto;
  max-width: 92%;
  object-fit: contain;
  object-position: center;
  margin: 12px auto 6px;
}
.hero .invite {
  margin: 0;
  font-size: 11px;
  line-height: 1.6;
}
#main:has(> .hero) .intro-strip {
  margin: 16px auto 0;
  padding: 12px 20px;
  gap: 8px;
  text-align: center;
}
#main:has(> .hero) .intro-strip blockquote {
  font-size: 13px;
  line-height: 1.8;
}
#main:has(> .hero) .intro-strip cite {
  margin-top: 3px;
  font-size: 11px;
  text-align: right;
}
body:has(#main > .hero) footer {
  width: 100%;
  margin-top: auto;
  padding-top: 10px;
  padding-bottom: 10px;
  font-size: 10px;
  line-height: 1.7;
}
@media (max-width: 800px) {
  body:has(#main > .hero) header {
    padding: 10px 18px 2px;
  }
  body:has(#main > .hero) .cloud {
    height: 68px;
    flex-basis: 110px;
  }
  .hero {
    margin-top: 8px;
  }
  .hero h1 {
    font-size: clamp(23px, 5.3vw, 30px);
  }
  .hero p {
    font-size: 12px;
  }
  .hero-art {
    height: clamp(160px, calc(100svh - 350px), 310px);
  }
  #main:has(> .hero) .intro-strip {
    margin: 12px 18px 0;
    padding: 10px 0;
  }
  #main:has(> .hero) .intro-strip blockquote {
    font-size: 12px;
  }
}
.cloud {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.4;
  padding: 0 20px;
}

.cloud small {
  max-width: 135px;
  margin: 4px auto 0;
  font-size: 10px;
  line-height: 1.4;
  white-space: normal;
}

@media (max-width: 800px) {
  body:has(#main > .hero) .cloud,
  .cloud {
    flex: 0 0 145px;
    font-size: 13px;
  }

  .cloud small {
    max-width: 110px;
    font-size: 9px;
  }
}
/* ზედა ნაწილი ყველა გვერდზე */
header {
  padding-top: 12px;
  padding-bottom: 4px;
}

nav {
  margin-top: 0;
}

.cloud {
  height: 76px;
}

.cloud:nth-child(even) {
  margin-top: 6px;
}

/* შიდა გვერდის დაშორებები */
.inside {
  margin: 18px auto 30px;
}

.crumb {
  margin-bottom: 14px;
}

.reading-layout {
  gap: 30px;
}

/* მარცხენა სარჩევი */
.sidebar h2 {
  font-size: 19px;
  margin-bottom: 12px;
}

.sidebar details {
  padding: 8px 0;
}

.sidebar summary {
  font-size: 13px;
  line-height: 1.6;
}

.sidebar .item {
  margin-top: 2px;
  padding: 6px 10px 6px 14px;
  line-height: 1.6;
}

/* კატეგორიის შესავალი */
.category-cover {
  padding-top: 0;
}

.category-cover h1,
.article h1 {
  font-size: 28px;
  line-height: 1.5;
  margin: 0 0 8px;
}

.category-cover p {
  margin: 8px auto;
}

.category-cover img {
  display: block;
  width: auto;
  max-width: 100%;
  max-height: 340px;
  object-fit: contain;
  margin: 12px auto;
}

/* სტატია — წაკითხვისთვის საკმარისი ზომით */
.article p {
  margin: 14px 0;
  line-height: 1.85;
}

.article figure {
  margin: 14px 0;
}

.article-bottom {
  margin-top: 20px;
  padding-top: 12px;
}

@media (max-width: 800px) {
  header {
    padding: 10px 18px 2px;
  }

  .cloud {
    height: 68px;
  }

  .inside {
    margin-top: 14px;
    padding: 0 18px;
  }

  .reading-layout {
    gap: 16px;
  }

  .category-cover h1,
  .article h1 {
    font-size: 24px;
  }

  .category-cover img {
    max-height: 260px;
  }
}

/* ღრუბლები ყველა გვერდზე */
#clouds {
  max-width: 1320px;
  gap: 10px;
}

#clouds .cloud {
  flex: 1 0 175px;
  min-width: 175px;
  height: 96px;
  padding: 0 18px;
  font-size: 14px;
  line-height: 1.4;
}

#clouds .cloud small {
  max-width: 140px;
  margin: 4px auto 0;
  font-size: 10px;
  line-height: 1.4;
}

/* ვიწრო ეკრანზე მენიუ გვერდულად გადაადგილდება */
@media (max-width: 1200px) {
  #clouds {
    overflow-x: auto;
    justify-content: flex-start;
  }
}

/* მობილურში მხოლოდ კატეგორიის სახელები */
@media (max-width: 800px) {
  #clouds .cloud {
    flex: 0 0 150px;
    min-width: 150px;
    height: 80px;
    font-size: 13px;
  }

  #clouds .cloud small {
    display: none;
  }
}

/* მთავარი გვერდის ღრუბლებიც */
body:has(#main > .hero) #clouds .cloud {
  flex: 1 0 175px;
  min-width: 175px;
  height: 96px;
}

@media (max-width: 800px) {
  body:has(#main > .hero) #clouds .cloud {
    flex: 0 0 150px;
    min-width: 150px;
    height: 80px;
  }

  #clouds .cloud small {
    display: none;
  }
}
