@font-face {
  font-family: "Pagella Site";
  src: url("/assets/pagella-site-2609-regular.woff2") format("woff2");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  unicode-range: U+0020-007E, U+00A0-017F, U+2013-2014, U+2018-201E, U+2022, U+2026, U+20BA, U+2660-2667;
}

@font-face {
  font-family: "Pagella Site";
  src: url("/assets/pagella-site-2609-italic.woff2") format("woff2");
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  unicode-range: U+0020-007E, U+00A0-017F, U+2013-2014, U+2018-201E, U+2022, U+2026, U+20BA, U+2660-2667;
}

@font-face {
  font-family: "Pagella Site";
  src: url("/assets/pagella-site-2609-bold.woff2") format("woff2");
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  unicode-range: U+0020-007E, U+00A0-017F, U+2013-2014, U+2018-201E, U+2022, U+2026, U+20BA, U+2660-2667;
}

/* Gece by default; güneş when the reader chooses it, or on otomatik when the system asks for light. */
:root {
  color-scheme: dark light;
  --bg: #16110d;
  --surface: #1f1812;
  --fg: #f3e9dc;
  --muted: #b9a58e;
  --nav: #d8c8b4;
  --accent: #f0b65a;
  --link-visited: #e0c49a;
  --suit-red: #ef7a72;
  --rule: #3a2c20;
}

@media (prefers-color-scheme: light) {
  :root:not([data-tema="gece"]) {
    --bg: #f7f1e8;
    --surface: #efe6d8;
    --fg: #1f1812;
    --muted: #6b5a47;
    --nav: #4a3b2d;
    --accent: #7a4a0c;
    --link-visited: #5c3d1e;
    --suit-red: #a8221c;
    --rule: #ddcdb6;
  }
}

:root[data-tema="gunes"] {
  color-scheme: light;
  --bg: #f7f1e8;
  --surface: #efe6d8;
  --fg: #1f1812;
  --muted: #6b5a47;
  --nav: #4a3b2d;
  --accent: #7a4a0c;
  --link-visited: #5c3d1e;
  --suit-red: #a8221c;
  --rule: #ddcdb6;
}

:root[data-tema="gece"] {
  color-scheme: dark;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: "Pagella Site", "Palatino Linotype", Palatino, "Book Antiqua", serif;
  font-size: 1.1875rem;
  line-height: 1.6;
  overflow-wrap: break-word;
  text-rendering: optimizeLegibility;
}

body > header,
main,
body > footer {
  max-width: 70rem;
  margin-inline: auto;
  padding-inline: 1.5rem;
}

main :is(p, li, blockquote) {
  max-width: 68ch;
}

img,
video {
  max-width: 100%;
}

body > header {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem 2rem;
  padding-block: 1.75rem 1rem;
  border-block-end: 1px solid var(--rule);
}

body > header > a,
body > header > a:visited {
  color: var(--fg);
  font-size: 1.6rem;
  font-weight: 700;
  text-decoration: none;
}

body > header ul,
body > footer ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.25rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

body > header nav a,
body > header nav a:visited {
  color: var(--nav);
  text-decoration: none;
}

body > header nav a[aria-current="page"] {
  color: var(--accent);
  text-decoration: underline 2px var(--accent);
  text-underline-offset: 0.3em;
}

body > footer {
  margin-block-start: 3rem;
  padding-block: 1rem 2rem;
  border-block-start: 1px solid var(--rule);
}

body > footer a,
body > footer a:visited {
  color: var(--muted);
}

body > header form {
  color: var(--nav);
}

body > header button {
  min-height: 44px;
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  color: var(--nav);
  cursor: pointer;
}

body > header button span {
  position: relative;
}

/* The active mode's mark: one box under the word for both, so the wave and the earth strip line up. */
body > header button span::after {
  --wave: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='6' viewBox='0 0 12 6'%3E%3Cpath d='M0 3Q3 0.8 6 3T12 3' fill='none' stroke='%237e9cd8' stroke-width='1.6'/%3E%3C/svg%3E") left center / 12px 6px repeat-x;
  --earth: linear-gradient(#c8641c 0 2px, #8a5d32 2px 6px);
  content: "";
  position: absolute;
  inset-inline: 0;
  top: calc(100% + 0.3em);
  height: 6px;
}

/* Pinned, the pressed button is marked; otherwise the device's mode is, gece unless it asks for light. */
body > header .gece[aria-pressed="true"],
:root:not([data-tema]) body > header .gece,
body > header .gunes[aria-pressed="true"] {
  color: var(--fg);
}

body > header .gece[aria-pressed="true"] span::after,
:root:not([data-tema]) body > header .gece span::after {
  background: var(--wave);
}

body > header .gunes[aria-pressed="true"] span::after {
  background: var(--earth);
}

@media (prefers-color-scheme: light) {
  :root:not([data-tema]) body > header .gece {
    color: var(--nav);
  }

  :root:not([data-tema]) body > header .gece span::after {
    background: none;
  }

  :root:not([data-tema]) body > header .gunes {
    color: var(--fg);
  }

  :root:not([data-tema]) body > header .gunes span::after {
    background: var(--earth);
  }
}

body > header button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

h1,
h2 {
  font-weight: 700;
}

h1 {
  font-size: 3.25rem;
  line-height: 1.1;
}

h2 {
  font-size: 2rem;
  line-height: 1.2;
}

a {
  color: var(--accent);
  text-decoration-line: underline;
  text-decoration-thickness: from-font;
  text-underline-offset: 0.15em;
}

a:visited {
  color: var(--link-visited);
}

a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.songs {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 18rem), 1fr));
  gap: 2rem 1.75rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.songs li {
  max-width: none;
}

.song-card,
.song-card:visited {
  display: block;
  color: var(--fg);
  text-decoration: none;
}

.song-card img {
  display: block;
  width: 100%;
  height: auto;
  margin-block-end: 0.6rem;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 4px;
  background: var(--surface);
}

.song-card em {
  display: block;
  color: var(--accent);
}

.song-card:hover span,
.song-card:focus-visible span {
  text-decoration: underline;
}

.song-trail {
  margin-block: 2rem 0;
  color: var(--muted);
}

.song-trail a,
.song-trail a:visited {
  color: var(--muted);
}

.song-trail + h1 {
  margin-block: 0.5rem 0;
}

.song-title {
  margin-block: 0.25rem 0.75rem;
  color: var(--accent);
  font-size: 1.9rem;
  font-style: italic;
  line-height: 1.2;
}

.credit {
  color: var(--muted);
}

.song-video {
  display: block;
  width: 100%;
  height: auto;
  margin-block: 1.5rem 2.5rem;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 6px;
  background: var(--surface);
}

.song-columns {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 26rem), 1fr));
  gap: 2rem 3rem;
}

.lyrics {
  font-size: 1.375rem;
  line-height: 1.7;
}

.lyrics > p:first-child {
  margin-block-start: 0;
}

aside h2 {
  margin-block: 0 0.75rem;
  color: var(--muted);
  font-size: 1.25rem;
}

aside ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

aside li + li {
  margin-block-start: 0.6rem;
}

/* The two song columns sit side by side from about this width. */
@media (min-width: 58rem) {
  aside {
    padding-inline-start: 2rem;
    border-inline-start: 1px solid var(--rule);
  }
}

.intro {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 26rem), 1fr));
  align-items: end;
  gap: 2rem 3rem;
  margin-block: 2.5rem 3.5rem;
}

.giris {
  font-size: 1.75rem;
  line-height: 1.4;
}

.giris > p:first-child {
  margin-block-start: 0;
  color: var(--accent);
  font-size: 4rem;
  font-style: italic;
  line-height: 1.1;
}

.newest {
  margin: 0;
}

.newest img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 4px;
  background: var(--surface);
}

.newest figcaption {
  margin-block-start: 0.6rem;
  color: var(--muted);
}

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem 2rem;
  margin-block-end: 1.25rem;
}

.section-head h2 {
  margin: 0;
}

.sections {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr));
  gap: 2rem 1.75rem;
  margin-block-start: 3.5rem;
  padding-block-start: 1.5rem;
  border-block-start: 1px solid var(--rule);
}

.sections h2 {
  margin-block: 0 0.5rem;
}

.suit-red {
  color: var(--suit-red);
}

/* On a phone the name sits above the navigation, and grids keep one column. */
@media (max-width: 24rem) {
  body > header {
    flex-direction: column;
  }

  .songs,
  .intro,
  .sections,
  .song-columns {
    grid-template-columns: 1fr;
  }
}
