/*!
 * Telltime Word Clock — styles.
 * Pairs with wordclock.js. All colours are CI tokens; adjust to match the theme.
 *
 * FONT: the clock words use the Telltime house font. The @font-face below points
 * to a WOFF2 next to this file. Convert Telltime-Regular.otf -> .woff2 for
 * production (smaller, cached). During review the .otf fallback is included too.
 */

@font-face {
    font-family: 'Telltime';
    src: url('../fonts/TelltimeRegular.woff2') format('woff2'),
        url('../fonts/TelltimeRegular.woff') format('woff');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

.ttwc {
  --ttwc-gold: #C9A96E;
  --ttwc-lit: #F6E3BC;
  --ttwc-unlit: rgba(20, 12, 4, .5);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 22px;
}

/* Clock face -------------------------------------------------------------- */
.ttwc-face {
  width: min(520px, 88vw);
  aspect-ratio: 1;
  border-radius: 18px;
  box-shadow: 0 40px 90px rgba(0, 0, 0, .6),
              0 0 0 1px rgba(255, 255, 255, .06),
              0 0 90px rgba(201, 169, 110, .10);
}
.ttwc-face svg { width: 100%; height: 100%; border-radius: 18px; display: block; }

.ttwc-word {
  font-family: 'Telltime', 'Saira Stencil One', 'Plus Jakarta Sans', Georgia, serif;
  fill: var(--ttwc-unlit);
  transition: fill .9s ease, filter .9s ease;
}
.ttwc-word.lit {
  fill: var(--ttwc-lit);
  filter: drop-shadow(0 0 7px rgba(246, 227, 188, .95)) drop-shadow(0 0 20px rgba(201, 169, 110, .6));
}
.ttwc-dot { fill: var(--ttwc-unlit); transition: fill .6s, filter .6s; }
.ttwc-dot.lit { fill: var(--ttwc-lit); filter: drop-shadow(0 0 6px rgba(246, 227, 188, .9)); }

/* Optional controls (scrubber) -------------------------------------------- */
.ttwc-controls { width: min(520px, 88vw); display: flex; flex-direction: column; gap: 10px; }
.ttwc-row { display: flex; align-items: center; gap: 16px; }
.ttwc-live {
  font-family: 'Inter', sans-serif; font-size: 11px; font-weight: 600; letter-spacing: 3px;
  padding: 8px 16px; cursor: pointer; background: transparent; border: 1px solid var(--ttwc-gold);
  color: var(--ttwc-gold); text-transform: uppercase; transition: all .3s;
}
.ttwc-live.active { background: var(--ttwc-gold); color: #0A0A0A; }
.ttwc-pulse { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: currentColor; margin-right: 8px; animation: ttwc-pulse 1.6s infinite; }
@keyframes ttwc-pulse { 0%, 100% { opacity: 1; } 50% { opacity: .25; } }
.ttwc-controls input[type=range] {
  flex: 1; appearance: none; -webkit-appearance: none; height: 2px;
  background: rgba(255, 255, 255, .2); outline: none; cursor: pointer;
}
.ttwc-controls input[type=range]::-webkit-slider-thumb {
  -webkit-appearance: none; width: 16px; height: 16px; border-radius: 50%;
  background: var(--ttwc-gold); border: none; box-shadow: 0 0 12px rgba(201, 169, 110, .7);
}
.ttwc-controls input[type=range]::-moz-range-thumb {
  width: 16px; height: 16px; border-radius: 50%; background: var(--ttwc-gold); border: none;
}
.ttwc-readout { display: flex; justify-content: space-between; align-items: baseline; }
.ttwc-digital { font-family: 'Plus Jakarta Sans', sans-serif; font-size: 14px; letter-spacing: 3px; color: rgba(255, 255, 255, .55); }
.ttwc-phrase { font-family: 'Cormorant Garamond', serif; font-size: 20px; letter-spacing: 1px; color: var(--ttwc-gold); font-style: italic; }

/* On a light background, switch the readout colours via a modifier class:
   <div class="ttwc ttwc--on-light" ...>  */
.ttwc--on-light .ttwc-digital { color: rgba(0, 0, 0, .5); }

@media (prefers-reduced-motion: reduce) {
  .ttwc-word, .ttwc-dot { transition: none; }
  .ttwc-pulse { animation: none; }
}