/* coalthekitten.com
   The page is a sheet of paper: white, inked in Kömür's own black. The only colours are the four crayons of the lessons,
   and each one says which episode it belongs to (blue butterfly 1, green frog 2, red apple 3, yellow star 4).
   One moving thing: the hero colours itself in. Everything else stays still and quiet. */

:root {
  --paper: #ffffff;
  --ink: #17151c;          /* Kömür's fur */
  --ink-2: #4a4552;        /* the same ink, softer: secondary text (8.9:1 on white) */
  --wash: #f4f2f6;         /* a faint grey for the frames of the pages to print */
  --blue: #2f7fe8;  --blue-ink: #1c4fb8;
  --green: #58cf3a; --green-ink: #23962c;
  --red: #ee2f2a;   --red-ink: #b8141a;
  --yellow: #ffd21f; --yellow-ink: #8a5a22;
  --font: "Baloo 2", system-ui, -apple-system, "Segoe UI", "Noto Sans", sans-serif;
  --gutter: 16px;
  --measure: 36rem;
  color-scheme: light;
}
@media (min-width: 600px) { :root { --gutter: 28px; } }
@media (min-width: 1000px) { :root { --gutter: 48px; } }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--font); font-size: 1.125rem; line-height: 1.55; font-weight: 400;
}
img, svg { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration-thickness: 2px; text-underline-offset: 0.18em; }
a:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3, h4 { margin: 0; line-height: 1.08; font-weight: 700; }
p { margin: 0; }

.wrap { max-width: 72rem; margin: 0 auto; padding: 0 var(--gutter); }

/* the top line: Kömür's badge home, the language */
.ust { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 14px; padding-bottom: 6px; }
.ust .rozet { display: block; width: 44px; height: 44px; border-radius: 50%; }
.ust .rozet img { width: 44px; height: 44px; border-radius: 50%; }
.ust .dil { font-size: 1rem; font-weight: 600; color: var(--ink-2); text-decoration: none; padding: 8px 0; }
.ust .dil:hover { color: var(--ink); text-decoration: underline; }

/* the hero: the colouring page that colours itself */
.giris { display: grid; gap: 8px; padding-top: 4px; padding-bottom: 16px; }
.giris-resim { margin: 0 auto; width: min(100%, 560px); }
.giris-resim svg { width: 100%; }
.giris h1 { font-size: clamp(3rem, 1.6rem + 6vw, 5.25rem); font-weight: 800; letter-spacing: -0.015em; line-height: 0.98; }
.giris .lead { margin-top: 14px; font-size: 1.3125rem; line-height: 1.45; max-width: 30rem; }
.giris .sub { margin-top: 10px; color: var(--ink-2); }
.dugmeler { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
@media (min-width: 880px) {
  .giris { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); align-items: center; gap: 40px; padding-top: 16px; padding-bottom: 24px; }
  .giris-yazi { order: 1; }
  .giris-resim { order: 2; width: 100%; max-width: 620px; }
}

/* buttons: the primary one in Kömür's black */
.dugme {
  display: inline-flex; align-items: center; min-height: 48px; padding: 6px 22px 4px;
  border-radius: 999px; border: 2.5px solid var(--ink); background: var(--paper); color: var(--ink);
  font-size: 1.125rem; font-weight: 700; text-decoration: none; line-height: 1.2;
}
.dugme:hover { background: var(--wash); }
.dugme-ana { background: var(--ink); color: var(--paper); }
.dugme-ana:hover { background: #2c2633; }

/* the crayon reveal (one moment, on load) */
.boya-yol { fill: none; stroke: #fff; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1 1; stroke-dashoffset: 1;
  animation: boya 0.62s cubic-bezier(.45, .05, .55, .95) forwards; }
.boya-1 { animation-delay: 0.35s; } .boya-2 { animation-delay: 0.9s; } .boya-3 { animation-delay: 1.45s; }
.boya-4 { animation-delay: 1.95s; } .boya-5 { animation-delay: 2.4s; } .boya-6 { animation-delay: 2.85s; }
.boya-tum { opacity: 0; animation: tum 0.7s ease 3.3s forwards; }
@keyframes boya { to { stroke-dashoffset: 0; } }
@keyframes tum { to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
  .boya-yol { animation: none; stroke-dashoffset: 0; }
  .boya-tum { animation: none; opacity: 1; }
}

/* sections */
.bolumler, .veliler, .diller { padding-top: 56px; padding-bottom: 8px; }
@media (min-width: 880px) { .bolumler, .veliler, .diller { padding-top: 88px; } }
.bolumler > h2, .veliler > h2, .diller > h2 { font-size: clamp(2rem, 1.5rem + 2vw, 2.625rem); margin-bottom: 28px; }

/* an episode: its crayon says which one it is */
.bolum { display: grid; gap: 18px; padding-bottom: 56px; grid-template-areas: "bas" "kapak" "govde" "sayfa"; }
.bolum .bas { grid-area: bas; } .bolum .kapak { grid-area: kapak; } .bolum .govde { grid-area: govde; } .bolum .sayfa-blok { grid-area: sayfa; }
.bolum + .bolum { padding-top: 8px; }
.bolum-mavi { --c: var(--blue); --c-ink: var(--blue-ink); }
.bolum-yesil { --c: var(--green); --c-ink: var(--green-ink); }
.bolum-kirmizi { --c: var(--red); --c-ink: var(--red-ink); }
.bolum-sari { --c: var(--yellow); --c-ink: var(--yellow-ink); }
.bolum .kapak img { width: 100%; border-radius: 14px; aspect-ratio: 16 / 9; object-fit: cover; }
.bolum .no { display: flex; align-items: center; gap: 10px; font-size: 1.0625rem; font-weight: 700; color: var(--c-ink); }
.bolum .leke { width: 34px; height: 26px; color: var(--c); flex: none; }
.bolum h3 { margin-top: 6px; font-size: clamp(1.75rem, 1.4rem + 1.4vw, 2.25rem); }
.bolum .konu { margin-top: 6px; font-weight: 600; color: var(--ink-2); }
.bolum .hikaye { max-width: var(--measure); }
.bolum .sor { margin-top: 14px; max-width: var(--measure); padding-inline-start: 14px; border-inline-start: 5px solid var(--c); }
.bolum .sor b { font-weight: 700; }
.bolum .izle { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin-top: 22px; }
.bolum .sure { color: var(--ink-2); font-weight: 600; }
.bolum h4 { margin-top: 10px; font-size: 1.3125rem; }
@media (min-width: 880px) {
  .bolum { grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); grid-template-rows: auto auto 1fr; column-gap: 44px; row-gap: 18px; align-items: start;
    grid-template-areas: "kapak bas" "kapak govde" "sayfa govde"; }
  .bolum h4 { margin-top: 6px; }
}

/* the pages to print */
.sayfalar { list-style: none; margin: 14px 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; max-width: 30rem; }
.sayfalar .kucuk { display: block; border: 3px solid var(--c); border-radius: 12px; overflow: hidden; background: var(--paper); }
.sayfalar .kucuk img { width: 100%; aspect-ratio: 210 / 297; object-fit: cover; }
.sayfalar .ad { display: block; margin-top: 8px; font-weight: 700; line-height: 1.25; }
.sayfalar .not { display: block; font-size: 0.9375rem; color: var(--ink-2); line-height: 1.3; }
.sayfalar .boy { display: flex; gap: 14px; margin-top: 4px; font-size: 1rem; font-weight: 600; }
.sayfalar .boy a { color: var(--c-ink); }

/* for parents: plain facts */
.bilgiler { list-style: none; margin: 0; padding: 0; display: grid; gap: 18px; max-width: 40rem; }
.bilgiler li { padding-inline-start: 30px; position: relative; }
.bilgiler li::before { content: ""; position: absolute; inset-inline-start: 4px; top: 0.62em; width: 12px; height: 12px; border-radius: 50%; background: var(--ink); }

/* Coal's names: the language switch is the list itself */
.adlar { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr)); gap: 18px 16px; }
.adlar .ad-k, .adlar .ad-d { text-align: left; }
[dir="rtl"] .adlar .ad-k, [dir="rtl"] .adlar .ad-d { text-align: right; }
.adlar .ad-k { display: block; font-size: 1.625rem; font-weight: 700; line-height: 1.2; }
.adlar .ad-d { display: block; font-size: 0.9375rem; color: var(--ink-2); line-height: 1.3; }
.adlar a { text-decoration: none; display: block; border-radius: 8px; }
.adlar a .ad-k { text-decoration: underline; text-decoration-thickness: 3px; text-underline-offset: 0.16em; text-decoration-color: var(--blue); }
.adlar a:hover .ad-k { color: var(--blue-ink); }
.adlar [aria-current] .ad-k { text-decoration-color: var(--ink); }
.adlar .yakinda { color: var(--ink-2); }

/* the foot */
.alt { margin-top: 72px; padding-bottom: 40px; font-size: 1rem; }
.alt-ic { padding-top: 28px; border-top: 3px solid var(--ink); display: grid; gap: 8px; }
.alt .yok { color: var(--ink-2); }

/* Scripts. Baloo 2 keeps the Latin letters on every page; each script gets Baloo's own sister where there is one (Arabic
   script: Baloo Bhaijaan 2; Bengali: Baloo Da 2; Tamil: Baloo Thambi 2; Devanagari is in Baloo 2), a rounded face where the
   family has none (Cyrillic: Nunito; Thai: Mali), and the system's face for Chinese, Japanese, Korean and Ethiopic (their
   fonts are too large to serve; Apple's rounded Japanese face first). All are served from this site, none from Google. */
html[lang="ar"] body, html[lang="ur"] body, html[lang="fa"] body { font-family: "Baloo 2", "Baloo Bhaijaan 2", system-ui, "Segoe UI", "Noto Sans Arabic", sans-serif; line-height: 1.75; }
html[lang="bn"] body { font-family: "Baloo 2", "Baloo Da 2", system-ui, "Noto Sans Bengali", sans-serif; line-height: 1.65; }
html[lang="ta"] body { font-family: "Baloo 2", "Baloo Thambi 2", system-ui, "Noto Sans Tamil", sans-serif; line-height: 1.65; }
html[lang="ru"] body { font-family: "Baloo 2", "Nunito", system-ui, sans-serif; }
html[lang="th"] body { font-family: "Baloo 2", "Mali", system-ui, "Noto Sans Thai", sans-serif; line-height: 1.7; }
html[lang="zh-Hans"] body { font-family: "Baloo 2", "PingFang SC", "Noto Sans CJK SC", "Microsoft YaHei", system-ui, sans-serif; line-height: 1.7; }
html[lang="zh-TW"] body { font-family: "Baloo 2", "PingFang TC", "Noto Sans CJK TC", "Microsoft JhengHei", system-ui, sans-serif; line-height: 1.7; }
html[lang="ja"] body { font-family: "Baloo 2", "Hiragino Maru Gothic ProN", "Hiragino Sans", "Noto Sans CJK JP", "Meiryo", system-ui, sans-serif; line-height: 1.7; }
html[lang="ko"] body { font-family: "Baloo 2", "Apple SD Gothic Neo", "Noto Sans CJK KR", "Malgun Gothic", system-ui, sans-serif; line-height: 1.7; }
html[lang="am"] body { font-family: "Baloo 2", "Noto Sans Ethiopic", "Kefa", "Nyala", "Ebrima", system-ui, sans-serif; line-height: 1.7; }
/* scripts whose letters join, stack or stand tall: no tight letter-spacing on the big name, and room above and below lines */
:is(html[lang="ar"], html[lang="ur"], html[lang="fa"], html[lang="hi"], html[lang="mr"], html[lang="bn"], html[lang="ta"], html[lang="th"],
    html[lang="am"], html[lang="zh-Hans"], html[lang="zh-TW"], html[lang="ja"], html[lang="ko"]) :is(h1, h2, h3, h4) { letter-spacing: 0; line-height: 1.25; }

/* the 404 page: a big number, Kömür's line drawing, his names as the way back */
.yok-sayfa { padding-top: 32px; padding-bottom: 56px; display: grid; gap: 18px; justify-items: start; }
.yok-sayfa .rozet img { width: 200px; height: 200px; }
.yok-sayfa h1 { font-size: clamp(4rem, 3rem + 6vw, 7rem); font-weight: 800; line-height: 1; }
.yok-sayfa .adlar { width: 100%; }
