/* CandyCrush.org — site styles (mobile-first, no web fonts) */
:root {
  --pink: #e8177d;
  --pink-soft: #fde7f2;
  --purple: #6a2bd9;
  --night: #2b1650;
  --yellow: #ffc928;
  --ink: #261c38;
  --muted: #5a5069;
  --bg: #fff8fb;
  --line: #f1dce9;
  --radius: 16px;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 76px; }
body {
  margin: 0;
  font: 16px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", "Helvetica Neue", Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  overflow-wrap: break-word;
}
img { max-width: 100%; height: auto; display: block; }
a { color: #b3115f; }
a:hover { color: var(--pink); }
h1, h2, h3 { line-height: 1.2; }
.wrap { width: 100%; max-width: 1180px; margin-inline: auto; padding-inline: 16px; }
.wrap.narrow { max-width: 800px; }

/* buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 22px; border-radius: 999px; border: 2px solid var(--pink);
  background: var(--pink); color: #fff; font: inherit; font-weight: 700; line-height: 1.25;
  text-decoration: none; cursor: pointer; text-align: center;
  box-shadow: 0 4px 12px rgba(232, 23, 125, .25); transition: transform .1s, box-shadow .2s;
}
.btn:hover { color: #fff; box-shadow: 0 6px 18px rgba(232, 23, 125, .35); }
.btn:active { transform: translateY(1px); }
.btn.ghost { background: #fff; color: var(--pink); box-shadow: none; }
.btn.ghost:hover { background: var(--pink-soft); color: var(--pink); }
.btn.big { padding: 14px 30px; font-size: 1.1rem; }
.btn svg { width: 18px; height: 18px; flex: none; }

/* header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: #fff; border-bottom: 1px solid var(--line);
}
.hdr { display: flex; align-items: center; gap: 10px; min-height: 60px; }
.logo {
  display: flex; align-items: center; gap: 8px; margin-inline-end: auto;
  color: var(--ink); text-decoration: none; font-weight: 800; font-size: 1.15rem; white-space: nowrap;
}
.logo:hover { color: var(--ink); }
.logo svg { width: 36px; height: 36px; flex: none; }
.logo small { color: var(--pink); font-size: 1em; font-weight: 800; }
.nav-toggle {
  display: inline-flex; flex-direction: column; justify-content: center; gap: 5px;
  width: 44px; height: 44px; padding: 0 11px; border: 1px solid var(--line); border-radius: 12px;
  background: #fff; cursor: pointer;
}
.nav-toggle span { display: block; height: 2.5px; border-radius: 2px; background: var(--ink); transition: transform .2s, opacity .2s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }
#site-nav {
  display: none; position: absolute; inset-inline: 0; top: 100%;
  background: #fff; border-bottom: 1px solid var(--line); box-shadow: 0 12px 24px rgba(60, 20, 80, .12);
  max-height: calc(100vh - 60px); overflow-y: auto;
}
#site-nav.open { display: block; }
#site-nav ul { list-style: none; margin: 0 auto; padding: 8px 16px 14px; max-width: 1180px; display: grid; gap: 2px; }
#site-nav a {
  display: block; padding: 11px 12px; border-radius: 10px;
  color: var(--ink); text-decoration: none; font-weight: 600;
}
#site-nav a:hover, #site-nav a[aria-current] { background: var(--pink-soft); color: var(--pink); }
@media (min-width: 1024px) {
  .nav-toggle { display: none; }
  #site-nav { display: block; position: static; flex: 0 1 auto; min-width: 0; background: none; border: 0; box-shadow: none; max-height: none; overflow: visible; }
  #site-nav ul { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 2px; padding: 8px 0; }
  #site-nav a { padding: 7px 11px; font-size: .95rem; white-space: nowrap; }
}

/* language switcher */
.lang { position: relative; }
.lang summary {
  display: flex; align-items: center; gap: 6px; height: 44px; padding: 0 12px;
  list-style: none; cursor: pointer; border: 1px solid var(--line); border-radius: 999px;
  background: #fff; font-weight: 700; font-size: .9rem; white-space: nowrap; user-select: none;
}
.lang summary::-webkit-details-marker { display: none; }
.lang summary svg { width: 18px; height: 18px; color: var(--pink); flex: none; }
.lang-name { display: none; }
@media (min-width: 640px) { .lang-code { display: none; } .lang-name { display: inline; } }
.lang-list {
  position: absolute; inset-inline-end: 0; top: calc(100% + 8px); z-index: 60;
  width: min(340px, calc(100vw - 24px)); padding: 8px;
  display: grid; grid-template-columns: 1fr 1fr; gap: 2px;
  background: #fff; border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 16px 36px rgba(60, 20, 80, .18);
}
.lang-list a { padding: 8px 10px; border-radius: 8px; color: var(--ink); text-decoration: none; font-size: .92rem; }
.lang-list a:hover { background: var(--pink-soft); }
.lang-list a[aria-current] { background: var(--pink); color: #fff; font-weight: 700; }

/* hero */
.hero {
  padding: 26px 0 16px; text-align: center;
  background:
    radial-gradient(circle at 0 26%, rgba(255, 201, 40, .3) 0 34px, transparent 35px),
    radial-gradient(circle at 100% 18%, rgba(106, 43, 217, .14) 0 46px, transparent 47px),
    radial-gradient(circle at 96% 96%, rgba(54, 196, 111, .16) 0 22px, transparent 23px),
    linear-gradient(180deg, #ffe1f0, var(--bg));
}
.hero h1 { margin: 0 0 10px; font-size: clamp(1.6rem, 5vw, 2.6rem); letter-spacing: -.01em; }
.hero .lead { max-width: 760px; margin: 0 auto; color: var(--muted); font-size: 1rem; }
@media (min-width: 700px) { .hero .lead { font-size: 1.05rem; } }
.hero-article { text-align: start; padding: 22px 0 26px; }
.hero-article .lead { margin: 0; font-size: 1.12rem; }
.crumbs { font-size: .9rem; color: var(--muted); margin-bottom: 10px; }
.crumbs a { color: var(--muted); }
.crumbs .sep { display: inline-block; margin-inline: 8px; }
[dir="rtl"] .crumbs .sep { transform: scaleX(-1); }

/* game */
.game { padding: 6px 0 22px; }
.game-frame {
  position: relative; width: 100%; aspect-ratio: 2 / 3; min-height: 420px; max-height: calc(100vh - 110px);
  margin-inline: auto; overflow: hidden; border-radius: 18px;
  background: linear-gradient(160deg, #5a2aa8, var(--night)); box-shadow: 0 14px 34px rgba(80, 20, 120, .28);
}
@supports (height: 100svh) { .game-frame { max-height: calc(100svh - 110px); } }
.game-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; }
.game-frame:fullscreen { width: 100%; max-height: none; border-radius: 0; aspect-ratio: auto; }
.game-loading { position: absolute; inset: 0; display: grid; place-items: center; color: #fff; font-weight: 600; }
@media (min-width: 700px) {
  .game-frame { aspect-ratio: 4 / 3; min-height: 0; max-height: none; width: max(340px, min(100%, 1000px, calc((100vh - 96px) * 4 / 3))); }
  .page-home .hero { padding: 22px 0 14px; }
}
.game-bar {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px 18px;
  max-width: 1000px; margin: 14px auto 0; text-align: center;
}
.game-bar .hint { margin: 0; color: var(--muted); font-size: .95rem; flex: 1 1 280px; }

/* sections */
.section { padding: 40px 0; }
.section.alt { background: #fff; border-block: 1px solid var(--line); }
.section h2 { margin: 0 0 8px; text-align: center; font-size: clamp(1.4rem, 3.6vw, 2rem); }
.section .sub { max-width: 660px; margin: 0 auto 24px; text-align: center; color: var(--muted); }
.section h2 + .grid, .section h2 + .stats, .section h2 + .faq { margin-top: 22px; }
.grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); margin: 0; padding: 0; list-style: none; }
.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px;
  box-shadow: 0 2px 10px rgba(120, 40, 120, .06);
}
.section.alt .card { background: var(--bg); }
.card h3 { margin: 0 0 6px; font-size: 1.1rem; display: flex; align-items: center; gap: 8px; }
.card p { margin: 0; color: var(--muted); }
.num {
  display: inline-grid; place-items: center; flex: none; width: 28px; height: 28px; border-radius: 50%;
  background: var(--pink); color: #fff; font-size: .9rem; font-weight: 800;
}
.steps .card { padding: 0; overflow: hidden; }
.steps img, .gallery img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; background: var(--night); }
.steps .body { padding: 14px 16px 18px; }
.feature { border-top: 4px solid var(--pink); }
.feature.f2 { border-top-color: var(--yellow); }
.feature.f3 { border-top-color: var(--purple); }
.feature.f4 { border-top-color: #36c46f; }
.feature.f5 { border-top-color: #3d8bff; }
.feature.f6 { border-top-color: #ff8a1f; }
.gallery figure { margin: 0; overflow: hidden; background: #fff; border: 1px solid var(--line); border-radius: 14px; }
.gallery figcaption { padding: 10px 14px 12px; color: var(--muted); font-size: .93rem; }
.more { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin: 24px 0 0; }
.candy { display: block; width: 46px; height: 46px; margin-bottom: 12px; border-radius: 50%; box-shadow: inset 0 -4px 0 rgba(0, 0, 0, .12); }
.c-striped { background: repeating-linear-gradient(90deg, #ff3f7f 0 7px, #fff 7px 12px); border: 3px solid #ff3f7f; }
.c-wrapped { background: radial-gradient(circle, #ffc928 0 42%, #ff8a1f 44% 100%); border-radius: 12px; transform: rotate(8deg); }
.c-bomb {
  background: radial-gradient(#ff3f7f 18%, transparent 21%) 0 0 / 12px 12px, radial-gradient(#ffc928 18%, transparent 21%) 6px 6px / 12px 12px, #3a2550;
}
.c-combo { background: conic-gradient(#ff3f7f, #ffc928, #36c46f, #3d8bff, #9b5cff, #ff3f7f); }
.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
@media (min-width: 760px) { .stats { grid-template-columns: repeat(4, 1fr); } }
.stat { padding: 20px 10px; text-align: center; color: #fff; border-radius: var(--radius); background: linear-gradient(135deg, var(--purple), var(--pink)); }
.stat b { display: block; font-size: 2.1rem; line-height: 1.1; }
.faq details { margin-bottom: 10px; background: #fff; border: 1px solid var(--line); border-radius: 12px; }
.faq summary { position: relative; padding: 14px 44px 14px 16px; cursor: pointer; font-weight: 700; list-style: none; }
[dir="rtl"] .faq summary { padding: 14px 16px 14px 44px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; inset-inline-end: 16px; top: 10px; color: var(--pink); font-size: 1.4rem; line-height: 1.2; }
.faq details[open] summary::after { content: "−"; }
.faq details p { margin: 0; padding: 0 16px 16px; color: var(--muted); }
.about p { font-size: 1.05rem; }
.link-card { display: block; text-decoration: none; color: var(--ink); transition: border-color .2s, transform .1s; }
.link-card:hover { border-color: var(--pink); color: var(--ink); }
.link-card h3 { color: #b3115f; }

/* more games (our other sites) */
.ng-grid { max-width: 800px; margin-inline: auto; }
.ng-card { display: flex; align-items: flex-start; gap: 14px; height: 100%; }
.ng-card img { width: 56px; height: 56px; flex: none; border-radius: 14px; }
.ng-card h3 { flex-wrap: wrap; }
.ng-new { padding: 2px 8px; border-radius: 999px; background: var(--pink); color: #fff; font-size: .7rem; font-weight: 800; letter-spacing: .05em; line-height: 1.5; }

/* article */
.prose { max-width: 72ch; margin-inline: auto; padding: 8px 16px 16px; font-size: 1.06rem; line-height: 1.75; }
.prose h2 { margin: 1.8em 0 .5em; font-size: 1.5rem; }
.prose > h2:first-child { margin-top: .6em; }
.prose h3 { margin: 1.5em 0 .4em; font-size: 1.18rem; }
.prose p { margin: 0 0 1em; }
.prose ul, .prose ol { margin: 0 0 1em; padding-inline-start: 1.4em; }
.prose li { margin: .35em 0; }
.prose li::marker { color: var(--pink); }
.table-wrap { margin: 1.3em 0; overflow-x: auto; background: #fff; border: 1px solid var(--line); border-radius: 12px; }
.prose table { width: 100%; min-width: 460px; border-collapse: collapse; font-size: .96rem; line-height: 1.5; }
.prose th, .prose td { padding: 10px 12px; text-align: start; vertical-align: top; border-bottom: 1px solid var(--line); }
.prose th { background: var(--pink-soft); }
@media (max-width: 599px) {
  .prose table { min-width: 0; font-size: .9rem; line-height: 1.45; hyphens: auto; }
  .prose th, .prose td { padding: 8px 9px; overflow-wrap: break-word; }
}
.prose tbody tr:last-child td { border-bottom: 0; }
.note { margin: 1.3em 0; padding: 12px 16px; background: #fff6d6; border-inline-start: 4px solid var(--yellow); border-radius: 10px; }
.note p:last-child { margin-bottom: 0; }
.cta { padding: 16px 0 8px; }
.cta-box { padding: 26px 20px; text-align: center; color: #fff; border-radius: 20px; background: linear-gradient(135deg, var(--purple), var(--pink)); }
.cta-box h2 { margin: 0 0 6px; font-size: 1.5rem; }
.cta-box p { margin: 0 0 16px; opacity: .95; }
.cta-box .btn { background: #fff; color: var(--pink); border-color: #fff; }

/* contact */
.contact-card { padding: 22px; }
.contact-card > p { margin: 0 0 12px; color: var(--ink); }
.contact-email { font-weight: 700; }
.contact-form { position: relative; display: grid; gap: 6px; margin-top: 18px; }
.contact-form label { margin-top: 8px; font-weight: 700; }
.contact-form .req { color: var(--pink); }
.contact-form input[type="text"], .contact-form input[type="email"], .contact-form textarea {
  width: 100%; padding: 11px 13px; font: inherit; font-weight: 400; color: var(--ink);
  background: #fff; border: 1px solid #d9c6d3; border-radius: 10px;
}
.contact-form textarea { min-height: 150px; resize: vertical; }
.contact-form input:focus, .contact-form textarea:focus { outline: 3px solid rgba(232, 23, 125, .25); border-color: var(--pink); }
.contact-form .hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.contact-form .btn { justify-self: start; margin-top: 10px; }
.contact-form .btn:disabled { opacity: .7; cursor: default; }
.form-status { margin: 6px 0 12px; padding: 12px 14px; border-radius: 10px; font-weight: 700; }
.form-status.ok { background: #e3f7ea; color: #17733d; }
.form-status.err { background: #fde8ec; color: #a3122f; }

/* 404 */
.notfound { padding: 50px 0 60px; }
.big404 { margin: 0; font-size: 5rem; font-weight: 900; line-height: 1; color: var(--pink); }

/* footer */
.site-footer { margin-top: 40px; padding: 30px 0 26px; background: var(--night); color: #e7dcf3; font-size: .95rem; }
.site-footer a { color: #fff; }
.foot p { margin: 0 0 10px; }
.foot-note { color: #cbb9e0; }
.foot-links { display: flex; flex-wrap: wrap; gap: 8px 20px; margin: 14px 0; padding: 0; list-style: none; }
.foot-copy { color: #b9a6d0; font-size: .9rem; }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* blocks of the original site in the new design */
.hero .lead { font-size: 1.05rem; }
.hero .btn { margin-top: 16px; }
.menu-pills { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 16px 0 0; padding: 0; list-style: none; }
.menu-pills a {
  display: block; padding: 6px 14px; border: 1px solid var(--line); border-radius: 999px;
  background: #fff; color: var(--ink); text-decoration: none; font-weight: 600; font-size: .95rem;
}
.menu-pills a:hover { background: var(--pink-soft); color: var(--pink); }
.game-full { position: relative; padding: 0; }
.game-full .cc-iframe { display: block; width: 100%; height: 700px; border: 0; }
@media (max-width: 1024px) { .game-full .cc-iframe { max-height: calc(100vh - 40px); } }
.start-preview {
  position: absolute; top: 50%; left: 50%; z-index: 10; transform: translate(-50%, -50%);
  display: flex; flex-direction: column; align-items: center; gap: 12px;
  width: max-content; max-width: min(402px, 85%); padding: 40px 34px; border-radius: 30px;
  text-align: center; color: #fff; background: rgba(43, 22, 80, .6);
}
.game__btn {
  padding: 14px 34px; border: 2px solid var(--pink); border-radius: 999px; background: var(--pink); color: #fff;
  font: inherit; font-size: 1.2rem; font-weight: 800; cursor: pointer; box-shadow: 0 6px 18px rgba(232, 23, 125, .45);
}
.game__help { font-weight: 600; }
.share-bar { padding: 0 16px; }
.share-bar .sharethis-inline-share-buttons, .share-bar .sharethis-inline-reaction-buttons { margin-top: 18px !important; }
.steps img.howto-img { aspect-ratio: 16 / 9; object-fit: contain; padding: 10px; background: var(--pink-soft); }
.feature-img { width: 72px; height: 72px; margin-bottom: 12px; }
.howto6 { max-width: 760px; margin: 22px auto 0; text-align: center; color: var(--muted); }
.howto6:empty { display: none; }
.faq summary h3 { display: inline; margin: 0; font-size: 1rem; line-height: 1.4; }
.faq details > div { padding: 0 16px 16px; color: var(--muted); }
.about-box { text-align: center; }
.about-box p { color: var(--muted); }
.lang-grid { display: grid; gap: 8px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); margin-top: 22px; }
.lang-grid a {
  display: flex; align-items: center; gap: 10px; padding: 9px 12px; border: 1px solid var(--line); border-radius: 12px;
  background: #fff; color: var(--ink); text-decoration: none; font-weight: 600;
}
.lang-grid a:hover { border-color: var(--pink); color: var(--pink); }
.lang-grid a[aria-current] { border-color: var(--pink); background: var(--pink-soft); }
.lang-grid .flag { width: 22px; height: 16px; object-fit: cover; border-radius: 3px; flex: none; }
.lang-grid .flag-none {
  display: inline-grid; place-items: center; font-size: 9px; font-weight: 800; color: #fff; background: var(--purple);
}
.cc-back { display: inline-block; margin-bottom: 12px; font-weight: 600; text-decoration: none; }
.about-page .about-img { width: 100%; max-width: 520px; margin: 4px auto 22px; border-radius: var(--radius); }
.legal .prose h5 { margin: 1.5em 0 .4em; font-size: 1.15rem; }
.legal .prose address { margin: 0 0 1em; font-style: normal; }
.legal .date { color: var(--muted); }
.card.prose { margin-block: 10px 0; }
