  @font-face { font-family: 'Cinzel';   font-weight: 400; font-display: swap;
    src: url('/assets/fonts/cinzel-400.woff2') format('woff2'),
         url('/assets/fonts/cinzel-400.woff')  format('woff'),
         url('/assets/fonts/cinzel-400.ttf')   format('truetype'); }
  @font-face { font-family: 'Cinzel';   font-weight: 700; font-display: swap;
    src: url('/assets/fonts/cinzel-700.woff2') format('woff2'),
         url('/assets/fonts/cinzel-700.woff')  format('woff'),
         url('/assets/fonts/cinzel-700.ttf')   format('truetype'); }
  @font-face { font-family: 'Cinzel';   font-weight: 900; font-display: swap;
    src: url('/assets/fonts/cinzel-900.woff2') format('woff2'),
         url('/assets/fonts/cinzel-900.woff')  format('woff'),
         url('/assets/fonts/cinzel-900.ttf')   format('truetype'); }
  @font-face { font-family: 'Rajdhani'; font-weight: 300; font-display: swap;
    src: url('/assets/fonts/rajdhani-300.woff2') format('woff2'),
         url('/assets/fonts/rajdhani-300.woff')  format('woff'),
         url('/assets/fonts/rajdhani-300.ttf')   format('truetype'); }
  @font-face { font-family: 'Rajdhani'; font-weight: 400; font-display: swap;
    src: url('/assets/fonts/rajdhani-400.woff2') format('woff2'),
         url('/assets/fonts/rajdhani-400.woff')  format('woff'),
         url('/assets/fonts/rajdhani-400.ttf')   format('truetype'); }
  @font-face { font-family: 'Rajdhani'; font-weight: 600; font-display: swap;
    src: url('/assets/fonts/rajdhani-600.woff2') format('woff2'),
         url('/assets/fonts/rajdhani-600.woff')  format('woff'),
         url('/assets/fonts/rajdhani-600.ttf')   format('truetype'); }

  * { margin: 0; padding: 0; box-sizing: border-box; }

  body {
    background: #000;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    min-height: 100vh;
    font-family: 'Rajdhani', sans-serif;
    padding: 20px;
    gap: 20px;
  }

  h1 {
    color: #00f5ff;
    font-family: 'Cinzel', serif;
    font-size: 1.1rem;
    letter-spacing: 4px;
    text-transform: uppercase;
    opacity: 0.7;
    margin-top: 10px;
  }

  /* Card — WhatsApp status ratio 9:16 */
  #card {
    position: relative;
    width: 360px;
    height: 640px;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 0 60px #00f5ff44, 0 0 120px #7b2fff22;
  }

  /* Deep space background */
  #bg {
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at 30% 20%, #0d1f4e 0%, #000510 60%);
    z-index: 0;
  }

  /* Star field */
  .stars { position: absolute; inset: 0; z-index: 1; }
  .star {
    position: absolute;
    border-radius: 50%;
    background: white;
    animation: twinkle var(--d) ease-in-out infinite alternate;
  }
  @keyframes twinkle {
    from { opacity: 0.1; transform: scale(0.8); }
    to   { opacity: 1;   transform: scale(1.2); }
  }

  /* Aurora */
  .aurora { position: absolute; inset: 0; z-index: 2; overflow: hidden; }
  .aurora::before, .aurora::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    animation: drift 8s ease-in-out infinite alternate;
  }
  .aurora::before {
    width: 280px; height: 280px; top: -60px; left: -60px;
    background: radial-gradient(circle, #00f5ff33, transparent 70%);
  }
  .aurora::after {
    width: 320px; height: 320px; bottom: -80px; right: -80px;
    background: radial-gradient(circle, #7b2fff33, transparent 70%);
    animation-delay: -4s;
  }
  @keyframes drift {
    from { transform: translate(0,0) scale(1); }
    to   { transform: translate(30px,20px) scale(1.15); }
  }

  /* Sigil — left:125px centers 110px element in 360px card without translateX */
  .sigil {
    position: absolute;
    top: 44px;
    left: 125px;
    width: 110px;
    height: 110px;
    z-index: 10;
  }
  .sigil svg {
    position: absolute;
    top: 0; left: 0;
    width: 110px;
    height: 110px;
    filter: drop-shadow(0 0 10px #00f5ff) drop-shadow(0 0 24px #00f5ff88);
  }
  .sigil-inner {
    position: absolute;
    top: 22px; left: 22px; right: 22px; bottom: 22px;
    border-radius: 50%;
    background: radial-gradient(circle, #0a1a3a, #000b1e);
    border: 1px solid #00f5ff55;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    animation: pulseCore 3s ease-in-out infinite alternate;
  }
  @keyframes pulseCore {
    from { box-shadow: 0 0 15px #00f5ff55 inset; }
    to   { box-shadow: 0 0 40px #00f5ffaa inset, 0 0 20px #00f5ff44; }
  }

  /* Decorative lines */
  .deco-line {
    position: absolute;
    left: 30px; right: 30px;
    height: 1px;
    background: linear-gradient(90deg, transparent, #00f5ff88, #7b2fff88, transparent);
    z-index: 10;
  }
  .deco-line.top    { top: 188px; }
  .deco-line.bottom { bottom: 175px; }

  /* Corner ornaments */
  .corner { position: absolute; width: 28px; height: 28px; z-index: 10; }
  .corner svg { width: 100%; height: 100%; }
  .corner.tl { top: 16px; left: 16px; }
  .corner.tr { top: 16px; right: 16px; transform: scaleX(-1); }
  .corner.bl { bottom: 16px; left: 16px; transform: scaleY(-1); }
  .corner.br { bottom: 16px; right: 16px; transform: scale(-1); }

  /* Quote content */
  .content {
    position: absolute;
    top: 196px;
    left: 24px; right: 24px;
    bottom: 183px;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 12px;
    min-height:0;
  }

  .day-label {
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.65rem;
    letter-spacing: 6px;
    color: #00f5ff;
    text-transform: uppercase;
    opacity: 0.8;
  }

  .quote-text {
    font-family: 'Cinzel', serif;
    font-size: clamp(0.7rem, 2.5vw, 1.05rem);
    line-height: 1.65;
    color: #e8f4ff;
    text-shadow: 0 0 20px #00f5ff66, 0 2px 4px #000;
    font-weight: 400;
    animation: fadeUp 0.8s ease both;
  }

  .quote-divider {
    width: 50px;
    height: 1px;
    background: linear-gradient(90deg, transparent, #00f5ff55, transparent);
    flex-shrink: 0;
  }

  .quote-fr {
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.78rem;
    line-height: 1.6;
    color: #a0d4e8;
    font-style: italic;
    opacity: 0.65;
    animation: fadeUp 0.8s ease 0.2s both;
  }

  .author {
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.7rem;
    letter-spacing: 4px;
    color: #7b2fff;
    text-transform: uppercase;
    opacity: 0.9;
    filter: drop-shadow(0 0 8px #7b2fff);
  }

  @keyframes fadeUp {
    from { opacity: 0; transform: translateY(16px); }
    to   { opacity: 1; transform: translateY(0); }
  }

  /* Date badge */
  .date-badge {
    position: absolute;
    bottom: 44px;
    left: 0; right: 0;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
  }
  .date-text {
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.7rem;
    letter-spacing: 3px;
    color: #00f5ffaa;
    text-transform: uppercase;
  }
  .date-dots { display: flex; gap: 5px; }
  .dot {
    width: 4px; height: 4px;
    border-radius: 50%;
    background: #7b2fff;
    animation: blink 2s ease-in-out infinite;
  }
  .dot:nth-child(2) { animation-delay: 0.3s; }
  .dot:nth-child(3) { animation-delay: 0.6s; }
  @keyframes blink {
    0%,100% { opacity: 0.3; }
    50%      { opacity: 1; }
  }

  /* Scan lines */
  .scanlines {
    position: absolute; inset: 0; z-index: 20;
    background: repeating-linear-gradient(0deg, transparent, transparent 3px, rgba(0,0,0,0.07) 3px, rgba(0,0,0,0.07) 4px);
    pointer-events: none;
    border-radius: 18px;
  }

  /* Edge glow */
  .edge-glow {
    position: absolute; inset: 0; z-index: 15;
    border-radius: 18px;
    box-shadow: inset 0 0 40px #00f5ff18, inset 0 0 80px #7b2fff0a;
    pointer-events: none;
  }

  /* Controls */
  .controls {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: center;
  }

  button {
    background: transparent;
    border: 1px solid #00f5ff66;
    color: #00f5ff;
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.8rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    padding: 10px 22px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s;
  }
  button:hover {
    background: #00f5ff15;
    border-color: #00f5ff;
    box-shadow: 0 0 20px #00f5ff44;
  }
  button.primary {
    border-color: #7b2fff99;
    color: #c084fc;
  }
  button.primary:hover {
    background: #7b2fff15;
    border-color: #7b2fff;
    box-shadow: 0 0 20px #7b2fff44;
  }
  #shareHint { display: none; }

  .hint {
    color: #ffffff33;
    font-size: 0.65rem;
    letter-spacing: 2px;
    text-align: center;
  }

  /* Archive panel */
  #archivePanel {
    display: none;
    flex-direction: column;
    gap: 8px;
    width: 360px;
    max-height: 320px;
    overflow-y: auto;
    border: 1px solid #00f5ff22;
    border-radius: 8px;
    padding: 10px;
    background: #000c1ecc;
    scrollbar-width: thin;
    scrollbar-color: #7b2fff33 transparent;
  }
  #archivePanel::-webkit-scrollbar { width: 4px; }
  #archivePanel::-webkit-scrollbar-thumb { background: #7b2fff55; border-radius: 2px; }

  .archive-header {
    font-family: 'Cinzel', serif;
    font-size: 0.6rem;
    letter-spacing: 4px;
    color: #00f5ff88;
    text-transform: uppercase;
    text-align: center;
    padding-bottom: 6px;
    border-bottom: 1px solid #00f5ff22;
    flex-shrink: 0;
  }

  .archive-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 8px 6px;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.2s;
    border-bottom: 1px solid #ffffff08;
  }
  .archive-item:hover { background: #00f5ff0a; }
  .archive-item.active { background: #7b2fff15; border-left: 2px solid #7b2fff; }

  .archive-num {
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.6rem;
    color: #00f5ff55;
    letter-spacing: 1px;
    min-width: 22px;
    padding-top: 2px;
  }
  .archive-text {
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.75rem;
    color: #c8dff0;
    line-height: 1.4;
    flex: 1;
  }
  .archive-text span {
    display: block;
    font-size: 0.65rem;
    color: #a0d4e866;
    font-style: italic;
    margin-top: 2px;
  }
  .archive-badge {
    font-size: 0.5rem;
    letter-spacing: 2px;
    padding: 2px 5px;
    border-radius: 2px;
    text-transform: uppercase;
    flex-shrink: 0;
    margin-top: 2px;
  }
  .archive-badge.new {
    background: #7b2fff33;
    color: #c084fc;
    border: 1px solid #7b2fff55;
  }
  .archive-badge.today {
    background: #00f5ff22;
    color: #00f5ff;
    border: 1px solid #00f5ff44;
  }

  .controls-row2 {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: center;
  }
  button.archive {
    border-color: #00f5ff33;
    color: #00f5ff88;
    font-size: 0.7rem;
    padding: 8px 16px;
  }
  button.archive:hover {
    background: #00f5ff0a;
    border-color: #00f5ff66;
    color: #00f5ff;
  }
  button.archive.open {
    border-color: #00f5ff88;
    color: #00f5ff;
    background: #00f5ff0a;
  }