@import url('https://fonts.googleapis.com/css2?family=Caveat:wght@400;500;600;700&display=swap');

:root { color: #f5f1e9; background: #171719; font-family: Caveat, 'Segoe Print', cursive; }
* { box-sizing: border-box; }
html, body, #app { min-height: 100%; margin: 0; }
body { min-width: 320px; background: #171719 url('../assets/backgrounds/dark-paper-texture-v1.webp') center / cover fixed; overflow-x: clip; }
button, a { font: inherit; }
button { cursor: pointer; }

.site-page { min-height: 100svh; padding: clamp(24px, 4vw, 72px); background: transparent; }
.site-page--home { display: grid; place-items: center; }
.home-shell { width: min(1360px, 100%); display: grid; justify-items: center; gap: clamp(68px, 8vw, 112px); }
.artist-logo { position: relative; width: 100%; aspect-ratio: 2556 / 615; }
.artist-logo__paper { position: absolute; z-index: 0; top: 50%; left: 50%; width: 104%; height: auto; transform: translate(-50%, -50%) rotate(-3deg); }
.artist-logo__mark { position: absolute; z-index: 1; top: 0; left: 0; display: block; width: 100%; height: auto; transform: translateY(-28.55%); }
.artist-logo__paper, .artist-logo__mark, .mini-brand__paper, .mini-brand__mark { pointer-events: none; }

.home-buttons { width: 100%; display: grid; grid-template-columns: 1fr 1fr 2.8fr 1fr 1fr; align-items: center; gap: clamp(18px, 2.5vw, 38px); }
.paper-button { position: relative; display: grid; place-items: center; min-width: 0; padding: 0; color: #1b1615; text-decoration: none; border: 0; background: none; transition: transform .18s ease, filter .18s ease; }
.paper-button__bg { position: absolute; inset: 0; display: block; width: 100%; height: 100%; min-height: 0; object-fit: fill; }
.social-paper .paper-button__bg,
.download-paper .paper-button__bg,
.browser-chip .paper-button__bg { filter: saturate(.64) brightness(1.08) contrast(.84); }
.paper-button__content { position: absolute; z-index: 1; inset: 12% 12%; display: flex; min-width: 0; align-items: center; justify-content: center; flex-direction: column; gap: 6px; text-align: center; line-height: .95; }
.paper-button:hover, .paper-button:focus-visible { transform: translateY(-7px) rotate(-1.5deg); filter: brightness(1.08); outline: none; }
.paper-button:active { transform: translateY(-1px) scale(.98); }
.drawn-icon { width: 32%; max-height: 43%; object-fit: contain; }
.paper-button__label, .paper-button__meta { max-width: 100%; overflow-wrap: anywhere; }
.paper-button__label { font-size: clamp(18px, 1.65vw, 24px); font-weight: 600; letter-spacing: .015em; }
.social-paper { aspect-ratio: 1.34 / 1; }
.social-paper .paper-button__label { white-space: nowrap; }
.mod-paper { aspect-ratio: 2.43 / 1; }
.mod-paper .paper-button__label { font-size: clamp(38px, 4.7vw, 64px); font-weight: 500; white-space: nowrap; }

.site-page--mod { padding-top: 34px; }
.mod-header { width: min(1120px, 100%); margin: 0 auto; display: flex; align-items: flex-start; justify-content: space-between; }
.mini-brand, .back-link { border: 0; padding: 0; color: #f5f1e9; background: none; font: 600 clamp(22px, 2vw, 31px)/1 Caveat, cursive; text-shadow: none; }
.mini-brand { width: 210px; aspect-ratio: 2556 / 615; background: none; }
.mini-brand > span { position: relative; display: block; width: 100%; height: 100%; }
.mini-brand__paper { position: absolute; z-index: 0; top: 50%; left: 50%; width: 112%; height: auto; transform: translate(-50%, -50%) rotate(-3deg); }
.mini-brand__mark { position: absolute; z-index: 1; top: 0; left: 0; display: block; width: 100%; height: auto; transform: translateY(-28.55%); }
.back-link { padding-top: 9px; }
.mod-shell { width: min(980px, 100%); margin: 50px auto 0; }
.mod-title-wrap { position: relative; width: min(640px, 100%); aspect-ratio: 2.43 / 1; min-height: 0; margin: 0 auto; }
.mod-title-wrap > img { position: absolute; inset: 0; width: 100%; height: 100%; min-height: 0; object-fit: fill; }
.mod-title-wrap h1 { position: absolute; inset: 0; display: grid; place-items: center; margin: 0; padding: 0 10% 2%; font-size: clamp(54px, 7vw, 90px); line-height: .9; font-weight: 500; color: #1c1615; text-align: center; }
.mod-subtitle-wrap { position: relative; width: min(760px, 98%); aspect-ratio: 4.7 / 1; min-height: 0; margin: 18px auto 62px; }
.mod-subtitle-wrap > img { position: absolute; inset: 0; width: 100%; height: 100%; min-height: 0; object-fit: fill; }
.mod-subtitle { position: absolute; inset: 18% 7%; display: grid; place-items: center; margin: 0; color: #3b3430; text-align: center; font-size: clamp(17px, 1.75vw, 23px); line-height: .9; letter-spacing: .035em; }
.download-grid { display: grid; min-width: 0; grid-template-columns: 1fr 1fr; gap: clamp(42px, 6vw, 78px); }
.download-paper--chrome { aspect-ratio: 1403 / 638; }
.download-paper--firefox { aspect-ratio: 1445 / 835; }
.download-paper--firefox .paper-button__bg { inset: -1% 0 1%; height: 102%; }
.download-paper .paper-button__content { inset: 13% 10%; gap: 5px; }
.drawn-icon--download { width: 21%; max-height: 32%; }
.download-paper .paper-button__label { font-size: clamp(25px, 2.65vw, 33px); }
.paper-button__meta { font-size: clamp(17px, 1.75vw, 22px); letter-spacing: .03em; opacity: .8; }
.browser-row { display: flex; min-width: 0; align-items: center; justify-content: center; gap: clamp(14px, 2.8vw, 38px); margin: 42px 0 46px; }
.browser-chip { width: clamp(100px, 12vw, 135px); align-self: center; }
.browser-chip--chrome, .browser-chip--edge { aspect-ratio: 973 / 519; }
.browser-chip--firefox { aspect-ratio: 917 / 393; }
.browser-chip--opera, .browser-chip--yandex { aspect-ratio: 1190 / 522; }
.browser-chip .paper-button__content { inset: 18% 13% 25%; }
.browser-chip .paper-button__label { font-size: clamp(17px, 1.65vw, 22px); line-height: .85; white-space: nowrap; }
.mod-info { padding-top: 30px; border-top: 1px solid rgba(245,241,233,.45); color: #f5f1e9; }
.mod-info h2 { margin: 0 0 9px; font-size: clamp(42px, 5vw, 57px); font-weight: 500; line-height: .9; }
.mod-info p { max-width: 780px; margin: 0; font-size: clamp(22px, 2.4vw, 29px); font-weight: 500; line-height: 1.19; }
.info-actions { display: flex; min-width: 0; flex-wrap: wrap; gap: 22px; margin-top: 24px; }
.info-actions .browser-chip { width: clamp(130px, 16vw, 180px); }

body.guide-open { overflow: hidden; }

.guide-modal[hidden] { display: none; }
.guide-modal {
  position: fixed;
  z-index: 30;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px 16px;
}
.guide-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(8, 9, 10, 0.78);
  backdrop-filter: blur(2px);
}
.guide-modal__panel {
  position: relative;
  z-index: 1;
  width: min(560px, 100%);
  max-height: min(88svh, 760px);
  overflow: auto;
  padding: 34px 28px 28px;
  color: #201b19;
  background:
    linear-gradient(180deg, rgba(255,252,245,.96), rgba(243,234,220,.98)),
    #f3eadd;
  border: 1px solid rgba(80, 60, 40, 0.18);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.45);
  transform: rotate(-0.6deg);
}
.guide-modal__body {
  position: relative;
  z-index: 1;
}
.guide-modal__body h2 {
  margin: 0 0 18px;
  font-size: clamp(36px, 7vw, 48px);
  font-weight: 600;
  line-height: .9;
  text-align: center;
  transform: rotate(-1deg);
}
.guide-modal__section + .guide-modal__section { margin-top: 16px; }
.guide-modal__section h3 {
  margin: 0 0 6px;
  font-size: clamp(24px, 4.5vw, 30px);
  font-weight: 600;
  line-height: 1;
}
.guide-modal__section ol {
  margin: 0;
  padding-left: 1.15em;
}
.guide-modal__section li {
  margin: 0 0 4px;
  font-size: clamp(18px, 3.4vw, 22px);
  font-weight: 500;
  line-height: 1.15;
}
.guide-modal__ack {
  display: block;
  width: min(240px, 100%);
  margin: 22px auto 0;
  padding: 12px 18px;
  border: 0;
  border-radius: 2px;
  background: #201b19;
  color: #f5f1e9;
  font: 600 clamp(22px, 4vw, 28px)/1 Caveat, cursive;
  transform: rotate(1deg);
  transition: transform .15s ease, filter .15s ease;
}
.guide-modal__ack:hover,
.guide-modal__ack:focus-visible {
  transform: translateY(-3px) rotate(-1deg);
  filter: brightness(1.08);
  outline: none;
}
.guide-modal__ack:active { transform: scale(.98); }

.site-loader { position: fixed; z-index: 20; inset: 0; display: grid; place-items: center; background: #08090a; opacity: 1; transition: opacity .32s ease, visibility .32s ease; }
.site-loader--done { opacity: 0; visibility: hidden; pointer-events: none; }
.site-loader__note { position: relative; display: grid; place-items: center; width: min(230px, 62vw); aspect-ratio: 2.35 / 1; color: #201b19; font: 600 clamp(22px, 5vw, 31px)/1 Caveat, cursive; }
.site-loader__note img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: fill; }
.site-loader__note span { position: relative; z-index: 1; transform: rotate(-2deg); }

@media (max-width: 760px) {
  .site-page { padding: 28px 20px 50px; }
  .home-shell { gap: 44px; }
  .artist-logo { width: min(430px, 100%); }
  .home-buttons { width: 100%; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px 18px; padding: 0 5px; }
  .mod-paper { grid-column: 1 / -1; grid-row: 1; width: min(100%, 420px); justify-self: center; }
  .social-paper { width: min(100%, 205px); justify-self: center; }
  .paper-button__label { font-size: 23px; }
  .mod-paper .paper-button__label { font-size: clamp(39px, 11vw, 56px); }
  .mod-header { gap: 15px; }
  .mini-brand { width: 140px; }
  .back-link { font-size: 20px; white-space: nowrap; }
  .mod-shell { margin-top: 46px; }
  .mod-title-wrap { width: 100%; }
  .mod-title-wrap h1 { font-size: clamp(50px, 14vw, 70px); }
  .mod-subtitle-wrap { width: 100%; margin: 18px auto 38px; aspect-ratio: 3.85 / 1; }
  .mod-subtitle { inset: 16% 8%; font-size: 16px; line-height: 1.02; }
  .download-grid { grid-template-columns: 1fr; gap: 22px; }
  .download-paper { width: min(100%, 500px); justify-self: center; }
  .download-paper .paper-button__content { inset: 9% 11% 14%; gap: 3px; }
  .download-paper .drawn-icon--download { width: 20%; max-height: 26%; }
  .download-paper .paper-button__label { font-size: clamp(22px, 6.3vw, 28px); line-height: .88; }
  .paper-button__meta { font-size: clamp(14px, 4vw, 17px); line-height: 1; }
  .browser-row { display: grid; grid-template-columns: repeat(2, minmax(0, 140px)); align-items: center; justify-content: center; gap: 16px 18px; margin-block: 28px; }
  .browser-chip { width: 100%; }
  .browser-chip .paper-button__content { inset: 18% 13% 26%; }
  .browser-chip .paper-button__label { font-size: 18px; }
  .mod-info { padding-top: 23px; }
  .mod-info h2 { font-size: 48px; }
  .mod-info p { font-size: 25px; line-height: 1.13; }
  .info-actions { gap: 12px; }
  .info-actions .browser-chip { width: calc(50% - 6px); }
}
