/* Quoker theme styles — vintage casino meets old library. Palette via theme.json tokens. */

body {
  background:
    radial-gradient(ellipse at 50% 15%, rgba(201, 169, 92, 0.07) 0%, rgba(0, 0, 0, 0) 45%),
    radial-gradient(ellipse at 50% 20%, #2a231a 0%, #16120d 75%);
  background-attachment: fixed;
}

::selection { background: var(--wp--preset--color--gold); color: var(--wp--preset--color--ink); }

/* ---------- Wordmark ---------- */
.qk-wordmark {
  font-family: var(--wp--preset--font-family--display);
  font-weight: 700;
  color: var(--wp--preset--color--parchment);
  letter-spacing: 0.04em;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  line-height: 1;
}
.qk-wordmark:hover { color: var(--wp--preset--color--parchment); }
.qk-wordmark .qk-chip-o {
  display: inline-block;
  width: 0.92em;
  height: 0.92em;
  margin: 0 0.03em;
  vertical-align: -0.08em;
}
.qk-wordmark--nav { font-size: 1.5rem; }
.qk-wordmark--hero { font-size: clamp(3rem, 9vw, 5.5rem); }
.qk-wordmark--hero::after {
  content: "";
  display: block;
}

/* ---------- Header ---------- */
.qk-header {
  border-bottom: 1px solid rgba(201, 169, 92, 0.28);
  background: rgba(22, 18, 13, 0.92);
  backdrop-filter: blur(6px);
  position: sticky;
  top: 0;
  z-index: 50;
}
.qk-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0.85rem 1.25rem;
}
.qk-nav {
  display: flex;
  align-items: center;
  gap: 1.6rem;
  flex-wrap: wrap;
}
.qk-nav a {
  font-family: var(--wp--preset--font-family--display);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--wp--preset--color--ivory);
  text-decoration: none;
  padding: 0.3rem 0;
  border-bottom: 2px solid transparent;
  transition: color 0.15s, border-color 0.15s;
}
.qk-nav a:hover, .qk-nav a:focus-visible { color: var(--wp--preset--color--gold); border-bottom-color: var(--wp--preset--color--gold); }
.qk-nav a.qk-nav-cta {
  background: var(--wp--preset--color--chip-red);
  color: var(--wp--preset--color--ivory);
  padding: 0.55rem 1.1rem;
  border-radius: 8px;
  border: 1px solid rgba(232, 220, 180, 0.25);
  border-bottom-width: 1px;
}
.qk-nav a.qk-nav-cta:hover, .qk-nav a.qk-nav-cta:focus-visible {
  background: #8f2f2b;
  border-color: var(--wp--preset--color--gold);
  color: var(--wp--preset--color--ivory);
}

/* ---------- Hero ---------- */
.qk-hero { padding: clamp(3rem, 7vw, 5.5rem) 1.25rem; }
.qk-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
  max-width: 1100px;
  margin: 0 auto;
}
.qk-hero-sub {
  font-family: var(--wp--preset--font-family--accent);
  font-style: italic;
  font-size: clamp(1.15rem, 2.4vw, 1.5rem);
  color: var(--wp--preset--color--gold);
  margin: 0.75rem 0 1.75rem;
  letter-spacing: 0.05em;
}
.qk-hero h1 {
  font-size: var(--wp--preset--font-size--xx-large);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  margin: 0 0 1.25rem;
}
.qk-hero-lead { font-size: 1.15rem; max-width: 34em; color: var(--wp--preset--color--ivory); }
.qk-hero-poster img, .qk-hero-poster { border-radius: 10px; }
.qk-hero-poster img {
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(201, 169, 92, 0.3);
  transform: rotate(1.5deg);
}
.qk-hero-poster--placeholder {
  aspect-ratio: 2 / 3;
  background: radial-gradient(ellipse at 50% 30%, #14453a 0%, #0d332a 100%);
  border: 1px solid rgba(201, 169, 92, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  text-align: center;
  font-family: var(--wp--preset--font-family--accent);
  font-style: italic;
  color: var(--wp--preset--color--parchment);
}
@media (max-width: 781px) {
  .qk-hero-grid { grid-template-columns: 1fr; }
  .qk-hero-poster { max-width: 380px; margin: 0 auto; }
}

/* ---------- Buttons ---------- */
.wp-block-button__link, .qk-btn {
  transition: background 0.15s, border-color 0.15s, transform 0.1s;
  border: 1px solid rgba(232, 220, 180, 0.25);
}
.wp-block-button__link:hover { border-color: var(--wp--preset--color--gold); transform: translateY(-1px); }
.is-style-qk-felt .wp-block-button__link {
  background: var(--wp--preset--color--felt);
  color: var(--wp--preset--color--ivory);
}
.is-style-qk-felt .wp-block-button__link:hover { background: var(--wp--preset--color--felt-deep); }

/* ---------- Chip divider ---------- */
.qk-divider {
  border: none !important;
  height: 44px !important;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Ccircle cx='50' cy='50' r='47' fill='%23a63a35'/%3E%3Cpath d='M50 3 A47 47 0 0 0 50 97 Z' fill='%233f6fa8'/%3E%3Ccircle cx='50' cy='50' r='42.5' fill='none' stroke='%23f2ecdc' stroke-width='7' stroke-dasharray='11.13 22.26' stroke-dashoffset='5.6' transform='rotate(-90 50 50)'/%3E%3Ccircle cx='50' cy='50' r='30' fill='%231c1712' stroke='%23c9a95c' stroke-width='2'/%3E%3Ctext x='50' y='64' text-anchor='middle' font-family='Georgia, serif' font-size='42' font-weight='bold' fill='%23e8dcb4'%3E%3F%3C/text%3E%3C/svg%3E") center / 34px 34px no-repeat,
    linear-gradient(to right, transparent 0%, rgba(201, 169, 92, 0.55) 18%, rgba(201, 169, 92, 0.55) calc(50% - 28px), transparent calc(50% - 28px), transparent calc(50% + 28px), rgba(201, 169, 92, 0.55) calc(50% + 28px), rgba(201, 169, 92, 0.55) 82%, transparent 100%) center / 100% 1px no-repeat !important;
  opacity: 1;
  width: 100%;
  max-width: 520px;
  margin-left: auto;
  margin-right: auto;
}

/* ---------- Cards / panels ---------- */
.qk-card {
  background: var(--wp--preset--color--smoke);
  border: 1px solid rgba(201, 169, 92, 0.3);
  border-radius: 10px;
  padding: 1.75rem !important;
  height: 100%;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.35);
}
.qk-card h3 { margin-top: 0; font-size: 1.15rem; letter-spacing: 0.04em; }

/* Subject tiles */
.qk-subjects .wp-block-column {
  background: radial-gradient(ellipse at 50% 30%, #14453a 0%, #0d332a 100%);
  border: 1px solid rgba(201, 169, 92, 0.35);
  border-radius: 8px;
  padding: 1rem 0.75rem !important;
  text-align: center;
  font-family: var(--wp--preset--font-family--display);
  font-weight: 600;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--wp--preset--color--parchment);
}
.qk-subjects .wp-block-column p { margin: 0; font-size: inherit; }

/* Check bullets */
.qk-checklist { list-style: none; padding-left: 0; }
.qk-checklist li { padding-left: 1.8em; position: relative; margin-bottom: 0.6em; }
.qk-checklist li::before {
  content: "\2713";
  position: absolute;
  left: 0;
  color: var(--wp--preset--color--gold);
  font-weight: 700;
}

/* CTA band */
.qk-cta-band {
  background: radial-gradient(ellipse at 50% 0%, #14453a 0%, #0d332a 90%);
  border-top: 1px solid rgba(201, 169, 92, 0.35);
  border-bottom: 1px solid rgba(201, 169, 92, 0.35);
}

/* ---------- Footer ---------- */
.qk-footer {
  border-top: 1px solid rgba(201, 169, 92, 0.28);
  margin-top: 4rem;
  padding: 2.5rem 1.25rem 3rem;
  text-align: center;
  color: rgba(242, 236, 220, 0.75);
  font-size: 0.9rem;
}
.qk-footer .qk-chip-o { width: 34px; height: 34px; }
.qk-footer-tagline {
  font-family: var(--wp--preset--font-family--accent);
  font-style: italic;
  color: var(--wp--preset--color--gold);
  font-size: 1.05rem;
  margin: 0.6rem 0 1rem;
}
.qk-footer .qk-nav { justify-content: center; margin-bottom: 1.25rem; }
.qk-footer-legal { font-size: 0.8rem; color: rgba(242, 236, 220, 0.55); max-width: 46em; margin: 0 auto; }

/* ---------- Content niceties ---------- */
.entry-content h2 { margin-top: 2.5em; text-transform: uppercase; letter-spacing: 0.05em; font-size: var(--wp--preset--font-size--x-large); }
.entry-content h2:first-child { margin-top: 0; }
.qk-pull {
  font-family: var(--wp--preset--font-family--accent);
  font-style: italic;
  font-size: 1.35rem;
  color: var(--wp--preset--color--parchment);
  border-left: 3px solid var(--wp--preset--color--gold);
  padding-left: 1.25rem;
}

/* ---------- Contact Form 7 ---------- */
.wpcf7 label { display: block; font-weight: 600; margin-bottom: 1.1rem; color: var(--wp--preset--color--parchment); }
.wpcf7 input[type="text"], .wpcf7 input[type="email"], .wpcf7 textarea {
  display: block;
  width: 100%;
  margin-top: 0.35rem;
  background: #201a13;
  border: 1px solid rgba(201, 169, 92, 0.4);
  border-radius: 6px;
  color: var(--wp--preset--color--ivory);
  padding: 0.7rem 0.85rem;
  font-family: inherit;
  font-size: 1rem;
}
.wpcf7 input:focus, .wpcf7 textarea:focus {
  outline: 2px solid var(--wp--preset--color--gold);
  outline-offset: 1px;
  border-color: var(--wp--preset--color--gold);
}
.wpcf7-checkbox .wpcf7-list-item { display: block; margin: 0.4rem 0 0; font-weight: 400; }
.wpcf7 input[type="submit"] {
  background: var(--wp--preset--color--chip-red);
  color: var(--wp--preset--color--ivory);
  font-family: var(--wp--preset--font-family--display);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border: 1px solid rgba(232, 220, 180, 0.25);
  border-radius: 8px;
  padding: 0.8rem 1.8rem;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}
.wpcf7 input[type="submit"]:hover { background: #8f2f2b; border-color: var(--wp--preset--color--gold); }
.wpcf7-response-output {
  border-color: var(--wp--preset--color--gold) !important;
  border-radius: 6px;
  color: var(--wp--preset--color--parchment);
}

/* Focus visibility site-wide */
a:focus-visible, button:focus-visible {
  outline: 2px solid var(--wp--preset--color--gold);
  outline-offset: 2px;
}

/* ---------- v1.0.1 fixes ---------- */
.qk-chip-o { display: inline-block; width: 1em; height: 1em; line-height: 0; }
.qk-wordmark .qk-chip-o { width: 0.92em; height: 0.92em; }
.qk-footer .qk-chip-o { width: 34px; height: 34px; }
.qk-hero h1 { font-size: clamp(1.7rem, 3.6vw, 2.7rem); }
.qk-wordmark--hero { font-size: clamp(2.4rem, 6.5vw, 4.2rem); }
.qk-hero-lead { font-size: 1.05rem; }
@media (max-width: 781px) {
  .qk-header-inner { justify-content: center; padding: 0.6rem 1rem; }
  .qk-nav { gap: 0.9rem 1.1rem; justify-content: center; }
  .qk-nav a { font-size: 0.74rem; }
  .qk-hero { padding: 2.25rem 1.25rem; }
  .qk-hero h1 { font-size: clamp(1.5rem, 6.5vw, 2rem); }
  .qk-wordmark--hero { font-size: clamp(2.1rem, 11vw, 3rem); }
}

/* ---------- v1.0.2 mobile pass ---------- */
@media (max-width: 781px) {
  .qk-header { position: static; }
  .qk-header-inner { padding: 0.55rem 0.75rem; gap: 0.4rem; }
  .qk-wordmark--nav { font-size: 1.35rem; }
  .qk-nav { gap: 0.5rem 0.9rem; }
  .qk-nav a { font-size: 0.7rem; letter-spacing: 0.06em; }
  .qk-nav a.qk-nav-cta { padding: 0.4rem 0.75rem; }
  main.wp-block-group { padding-left: 1.1rem; padding-right: 1.1rem; }
  .qk-hero { padding: 1.9rem 1.1rem 2.4rem; }
  .qk-hero-sub { margin: 0.4rem 0 1.1rem; }
  .qk-hero-grid { gap: 1.6rem; }
  .qk-subjects { display: grid !important; grid-template-columns: 1fr 1fr; gap: 0.6rem !important; margin-bottom: 0.6rem; }
  .qk-subjects .wp-block-column { flex-basis: auto !important; margin: 0 !important; }
  .qk-card { padding: 1.25rem !important; }
  body { background-attachment: scroll; }
  .qk-cta-band { padding: 2.5rem 1.1rem !important; margin-top: 2rem !important; }
  .qk-footer { padding: 2rem 1rem 2.5rem; margin-top: 2.5rem; }
}

/* ---------- v1.0.3: form fit + mobile nav & home polish ---------- */
.wpcf7 input, .wpcf7 textarea { box-sizing: border-box; max-width: 100%; }
@media (max-width: 781px) {
  .qk-header-inner { flex-direction: column; padding: 0.5rem 0.6rem 0.55rem; gap: 0.3rem; }
  .qk-wordmark--nav { font-size: 1.25rem; }
  .qk-nav { gap: 0.35rem 0.7rem; width: 100%; justify-content: center; }
  .qk-nav a { font-size: 0.68rem; padding: 0.15rem 0; }
  .qk-nav a.qk-nav-cta { padding: 0.3rem 0.6rem; border-radius: 6px; }
  .qk-hero { padding: 1.6rem 1.1rem 2rem; }
  .qk-hero-copy { text-align: center; }
  .qk-hero h1 { font-size: clamp(1.35rem, 5.8vw, 1.7rem); margin-bottom: 0.9rem; }
  .qk-wordmark--hero { font-size: clamp(1.9rem, 10vw, 2.6rem); }
  .qk-hero-sub { font-size: 1.05rem; margin: 0.3rem 0 1rem; }
  .qk-hero-lead { font-size: 0.98rem; margin-left: auto; margin-right: auto; }
  .qk-hero-copy .wp-block-buttons { justify-content: center; }
  .qk-hero-poster { max-width: 270px; margin: 0 auto; }
  .qk-hero-poster img { transform: none; }
  .wpcf7 textarea { height: 8rem; }
  .wpcf7 input[type="submit"] { width: 100%; }
}

/* ---------- v1.0.4: image overflow fix ---------- */
img { max-width: 100%; height: auto; }
.qk-hero-poster img { display: block; width: 100%; height: auto; }

/* ---------- v1.1.0: demo hand, card flip, ambience ---------- */

/* Demo hand */
.qkd-section { padding: 3rem 1.25rem 1rem; text-align: center; }
.qkd-inner { max-width: 640px; margin: 0 auto; }
.qkd-title { text-transform: uppercase; letter-spacing: 0.06em; margin: 0 0 0.3rem; }
.qkd-tag { font-family: var(--wp--preset--font-family--accent); font-style: italic; color: var(--wp--preset--color--gold); font-size: 1.15rem; margin: 0 0 1.5rem; }
.qkd-table {
  position: relative; overflow: hidden;
  background: radial-gradient(ellipse at 50% 25%, #17503f 0%, #0d332a 100%);
  border: 1px solid rgba(201, 169, 92, 0.5); border-radius: 16px;
  box-shadow: inset 0 0 60px rgba(0,0,0,0.45), 0 14px 40px rgba(0,0,0,0.5);
  padding: 2.25rem 1.5rem 2.5rem; min-height: 300px;
  display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 0.9rem;
}
.qkd-label { font-family: var(--wp--preset--font-family--accent); font-style: italic; color: var(--wp--preset--color--parchment); font-size: 1.2rem; margin: 0; }
.qkd-cat { font-family: var(--wp--preset--font-family--display); font-weight: 700; font-size: clamp(1.5rem, 4vw, 2.2rem); text-transform: uppercase; letter-spacing: 0.1em; color: var(--wp--preset--color--parchment); text-shadow: 0 2px 14px rgba(0,0,0,0.6); }
.qkd-sub { color: var(--wp--preset--color--ivory); opacity: 0.85; margin: 0; font-size: 0.98rem; }
.qkd-chipcount, .qkd-pot { font-size: 0.95rem; color: var(--wp--preset--color--gold); letter-spacing: 0.04em; }
.qkd-q { font-size: 1.2rem; font-weight: 600; color: var(--wp--preset--color--ivory); max-width: 32em; }
.qkd-actions, .qkd-opts { display: flex; flex-wrap: wrap; gap: 0.6rem; justify-content: center; }
.qkd-opts { display: grid; grid-template-columns: 1fr 1fr; gap: 0.6rem; width: 100%; max-width: 460px; }
.qkd-btn {
  font-family: var(--wp--preset--font-family--display); font-weight: 600; font-size: 0.85rem;
  text-transform: uppercase; letter-spacing: 0.07em; text-decoration: none;
  background: var(--wp--preset--color--smoke); color: var(--wp--preset--color--parchment);
  border: 1px solid rgba(201, 169, 92, 0.5); border-radius: 8px;
  padding: 0.7rem 1rem; cursor: pointer; transition: transform 0.1s, border-color 0.15s, background 0.15s;
}
.qkd-btn span { display: block; font-family: var(--wp--preset--font-family--body); font-size: 0.68rem; text-transform: none; letter-spacing: 0; opacity: 0.75; margin-top: 0.15rem; }
.qkd-btn:hover { border-color: var(--wp--preset--color--gold); transform: translateY(-1px); }
.qkd-btn-green { background: var(--wp--preset--color--felt-deep); color: var(--wp--preset--color--ivory); }
.qkd-btn-red { background: var(--wp--preset--color--chip-red); color: var(--wp--preset--color--ivory); }
.qkd-btn-ghost { background: transparent; opacity: 0.75; }
.qkd-opt { font-family: var(--wp--preset--font-family--body); text-transform: none; letter-spacing: 0; font-size: 0.98rem; }
.qkd-verdict { font-family: var(--wp--preset--font-family--display); font-weight: 700; font-size: 1.6rem; text-transform: uppercase; letter-spacing: 0.06em; }
.qkd-good { color: #8fd6a8; } .qkd-bad { color: #e08a86; }
.qkd-timerbar { width: 100%; max-width: 460px; height: 5px; background: rgba(0,0,0,0.4); border-radius: 3px; overflow: hidden; }
.qkd-timerbar span { display: block; height: 100%; width: 100%; background: linear-gradient(to right, var(--wp--preset--color--gold), var(--wp--preset--color--chip-red)); transition-property: width; transition-timing-function: linear; }
.qkd-timerbar span.qkd-run { width: 0; }
.qkd-chip { position: absolute; top: -30px; width: 26px; height: 26px; border-radius: 50%; border: 4px dashed #f2ecdc; animation: qkd-fall linear forwards; pointer-events: none; }
.qkd-chip-r { background: var(--wp--preset--color--chip-red); } .qkd-chip-b { background: var(--wp--preset--color--chip-blue); }
@keyframes qkd-fall { to { transform: translateY(420px) rotate(340deg); opacity: 0.2; } }

/* Card flip */
.qk-flip-section { padding: 3.5rem 1.25rem 2rem; text-align: center; }
.qk-flip-scene { perspective: 1200px; display: inline-block; }
.qk-flip-card { position: relative; width: 210px; height: 300px; cursor: pointer; transform-style: preserve-3d; transition: transform 0.9s cubic-bezier(0.4, 0, 0.2, 1); }
.qk-flip-card.is-flipped { transform: rotateY(180deg); }
.qk-flip-face {
  position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden;
  border-radius: 12px; display: flex; align-items: center; justify-content: center;
  border: 1px solid rgba(201, 169, 92, 0.6); box-shadow: 0 16px 44px rgba(0,0,0,0.55);
}
.qk-flip-face p { font-family: var(--wp--preset--font-family--accent); font-style: italic; font-size: 1.45rem; margin: 0; padding: 0 1.2rem; line-height: 1.35; }
.qk-flip-front { background: linear-gradient(150deg, #f2ecdc 0%, #e2d6b4 100%); color: #241c12; }
.qk-flip-back { background: radial-gradient(ellipse at 50% 30%, #2f2517 0%, #16120d 100%); color: var(--wp--preset--color--parchment); transform: rotateY(180deg); }
.qk-flip-corner { position: absolute; top: 10px; left: 12px; font-family: var(--wp--preset--font-family--display); font-weight: 700; font-size: 1.1rem; color: var(--wp--preset--color--chip-red); }
.qk-flip-back .qk-flip-corner { color: var(--wp--preset--color--gold); }
.qk-flip-corner-b { top: auto; left: auto; bottom: 10px; right: 12px; transform: rotate(180deg); }
.qk-flip-caption { max-width: 30em; margin: 1.5rem auto 0; color: var(--wp--preset--color--ivory); opacity: 0.85; }

/* Hero ambience */
.qk-hero { position: relative; overflow: hidden; }
.qk-hero-grid { position: relative; z-index: 1; }
.qk-ambient { position: absolute; inset: 0; pointer-events: none; z-index: 0; }
.qk-float { position: absolute; bottom: -2rem; color: rgba(232, 220, 180, 0.16); font-family: var(--wp--preset--font-family--display); font-weight: 700; animation: qk-rise linear infinite; }
@keyframes qk-rise { from { transform: translateY(0) rotate(-8deg); } to { transform: translateY(-115vh) rotate(10deg); } }
.qk-spark { position: absolute; width: 3px; height: 3px; border-radius: 50%; background: rgba(201, 169, 92, 0.8); animation: qk-twinkle ease-in-out infinite; }
@keyframes qk-twinkle { 0%, 100% { opacity: 0; } 50% { opacity: 0.9; } }
.qk-wordmark:hover .qk-chip-o svg { animation: qk-spin 0.9s ease-in-out; }
@keyframes qk-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) {
  .qk-flip-card { transition: none; }
  .qk-float, .qk-spark, .qkd-chip { display: none; }
}
@media (max-width: 781px) {
  .qkd-table { padding: 1.75rem 1rem 2rem; }
  .qkd-opts { grid-template-columns: 1fr; }
  .qk-flip-card { width: 180px; height: 258px; }
}

/* ---------- v1.1.2: Whitfield.IT credit ---------- */
.qk-credit { margin-top: 1.6rem; }
.qk-credit a { display: inline-flex; align-items: center; gap: 0.55rem; text-decoration: none; opacity: 0.75; transition: opacity 0.15s; }
.qk-credit a:hover { opacity: 1; }
.qk-credit img { height: 22px; width: auto; }
.qk-credit span { font-size: 0.8rem; color: rgba(242, 236, 220, 0.7); letter-spacing: 0.03em; }
