/* Sakal Lit Fest links: custom styles layered on Tailwind utilities */

:root {
  --ink: #171717;
  --cream: #f4f0e8;
  --lit: #cd344a;
  --zap: #ffff00;
  --line: rgba(23, 23, 23, 0.1);
  --soft: rgba(23, 23, 23, 0.06);
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--cream);
  color: var(--ink);
}

a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 3px;
  border-radius: 1rem;
}

/* Yellow highlighter behind text */
.mark {
  background: linear-gradient(transparent 55%, var(--zap) 55%, var(--zap) 92%, transparent 92%);
  padding: 0 0.15em;
}

/* Section headings */
.section-title {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  font-family: 'Anton', Impact, sans-serif;
  font-size: 1.625rem;
  line-height: 1;
  text-transform: uppercase;
}

/* Round icon buttons (social links + share) */
.icon-btn {
  display: grid;
  place-items: center;
  flex: none;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--line);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.icon-btn:hover {
  border-color: var(--ink);
  box-shadow: 2px 2px 0 var(--ink);
  transform: translate(-1px, -1px);
  color: var(--brand, var(--ink));
}

/* Social links under the countdown */
.socials-label {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(23, 23, 23, 0.5);
}

.socials-label::before,
.socials-label::after {
  content: '';
  width: 2rem;
  height: 1px;
  background: rgba(23, 23, 23, 0.15);
}

.socials .icon-btn {
  width: 2.5rem;
  height: 2.5rem;
}

.socials .icon-btn svg {
  width: 1.125rem;
  height: 1.125rem;
}

/* Countdown */
.cd-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 3.75rem;
  padding: 0.6rem 0.5rem 0.5rem;
  border-radius: 0.875rem;
  background: var(--ink);
  color: #fff;
}

.cd-box span {
  font-family: 'Anton', Impact, sans-serif;
  font-size: 1.625rem;
  line-height: 1;
  color: var(--zap);
  font-variant-numeric: tabular-nums;
}

.cd-box small {
  margin-top: 0.3rem;
  font-size: 0.625rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  opacity: 0.7;
}

@media (min-width: 400px) {
  .cd-box {
    min-width: 4.25rem;
    padding: 0.6rem 0.75rem 0.5rem;
  }
  .cd-box span {
    font-size: 1.75rem;
  }
}

/* Shared hover: lift with a hard ink shadow */
.link-card,
.ticket,
.feature-card,
.chip {
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.link-card:hover,
.ticket:hover,
.feature-card:hover,
.chip:hover {
  border-color: var(--ink);
  box-shadow: 4px 4px 0 var(--ink);
  transform: translate(-2px, -2px);
}

/* Link cards */
.link-card {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  padding: 0.75rem 1rem 0.75rem 0.75rem;
  border: 1px solid var(--line);
  border-radius: 1rem;
  background: #fff;
}

.link-icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 0.75rem;
  background: var(--cream);
}

.link-icon svg {
  width: 1.25rem;
  height: 1.25rem;
}

.link-arrow {
  flex: none;
  width: 1.125rem;
  height: 1.125rem;
  opacity: 0.35;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.link-card:hover .link-arrow {
  opacity: 1;
  transform: translate(2px, -2px);
}

.link-card[href^='#']:hover .link-arrow {
  transform: translateY(2px);
}

.link-card--primary {
  background: var(--lit);
  border-color: var(--ink);
  color: #fff;
  box-shadow: 4px 4px 0 var(--ink);
}

.link-card--primary .link-icon {
  background: rgba(255, 255, 255, 0.16);
}

.link-card--primary .link-arrow {
  opacity: 0.9;
}

.link-card--primary:hover {
  box-shadow: 6px 6px 0 var(--ink);
}

/* Ticket cards with a perforated stub */
.ticket {
  position: relative;
  display: flex;
  align-items: center;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 1rem;
  background: #fff;
}

.ticket-stub {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  align-self: stretch;
  flex: none;
  width: 4.25rem;
  padding: 0.75rem 0;
  border-right: 2px dashed var(--line);
}

.ticket-stub::before,
.ticket-stub::after {
  content: '';
  position: absolute;
  right: -9px;
  width: 16px;
  height: 16px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--cream);
  transition: border-color 0.2s ease;
}

.ticket-stub::before {
  top: -9px;
}

.ticket-stub::after {
  bottom: -9px;
}

.ticket:hover .ticket-stub::before,
.ticket:hover .ticket-stub::after {
  border-color: var(--ink);
}

.ticket-stub b {
  font-family: 'Anton', Impact, sans-serif;
  font-size: 1.625rem;
  font-weight: 400;
  line-height: 1.1;
}

.ticket-stub small {
  font-size: 0.625rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0.55;
}

.ticket-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
  padding: 0.75rem 0.5rem 0.75rem 1rem;
}

.ticket-code {
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--lit);
}

.ticket-title {
  font-weight: 700;
  line-height: 1.3;
}

/* Show time: bold pill with a clock icon so it stands out from the hall name */
.ticket-time {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  align-self: flex-start;
  margin-top: 0.375rem;
  padding: 0.2rem 0.55rem 0.2rem 0.45rem;
  border-radius: 999px;
  background: var(--cream);
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

.ticket-time::before {
  content: '';
  width: 0.8rem;
  height: 0.8rem;
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.5' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='9.5'/%3E%3Cpath d='M12 7v5l3 2'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.5' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='9.5'/%3E%3Cpath d='M12 7v5l3 2'/%3E%3C/svg%3E") center / contain no-repeat;
}

.ticket-meta {
  margin-top: 0.3rem;
  font-size: 0.75rem;
  color: rgba(23, 23, 23, 0.6);
}

.ticket--live {
  border-color: var(--ink);
}

.ticket--live .ticket-stub {
  background: var(--zap);
}

/* Festival pass: a big ticket with a yellow stub that "tears off" at the dashed line */
.pass-card {
  position: relative;
  display: block;
  border: 1px solid var(--ink);
  border-radius: 1.25rem;
  background: #fff;
  transition: transform 0.2s ease;
}

.pass-card:hover {
  transform: translateY(-2px);
}

.pass-top {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1rem 1rem 1.125rem;
  border-bottom: 2px dashed rgba(23, 23, 23, 0.3);
  border-radius: calc(1.25rem - 1px) calc(1.25rem - 1px) 0 0;
  background: var(--zap);
  text-align: center;
}

/* Half-circle notches on both edges of the tear line */
.pass-top::before,
.pass-top::after {
  content: '';
  position: absolute;
  bottom: -11px;
  width: 22px;
  height: 22px;
  border: 1px solid var(--ink);
  border-radius: 50%;
  background: var(--cream);
}

.pass-top::before {
  left: -11.5px;
  clip-path: inset(0 0 0 50%);
}

.pass-top::after {
  right: -11.5px;
  clip-path: inset(0 50% 0 0);
}

.pass-month {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.pass-days {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.pass-days > span {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 3.5rem;
  padding: 0.55rem 0.5rem 0.5rem;
  border-radius: 0.75rem;
  background: var(--ink);
  color: #fff;
  font-family: 'Anton', Impact, sans-serif;
  font-size: 1.375rem;
  line-height: 1;
}

.pass-card .btn-submit,
.pass-card .btn-submit:hover {
  padding: 0.75rem 1rem;
  border: 0;
  font-size: 1rem;
  box-shadow: none;
  transform: none;
}

.pass-days small {
  margin-bottom: 0.2rem;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.625rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0.7;
}

/* Pills */
.pill {
  flex: none;
  margin-right: 0.875rem;
  padding: 0.4rem 0.8rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
}

.pill--book {
  background: var(--lit);
  color: #fff;
}

.pill--soon {
  background: var(--soft);
  color: rgba(23, 23, 23, 0.55);
}

.pill--map {
  margin-right: 0;
  background: var(--ink);
  color: #fff;
}

/* Feature card (Bal Sahitya) */
.feature-card {
  display: block;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 1.25rem;
  background: #fff;
}

/* Speaker slider: three cards per slide, swipeable, auto-advanced by main.js */
.scroller {
  display: flex;
  gap: 0.75rem;
  padding: 0.25rem 0 0.5rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

.scroller::-webkit-scrollbar {
  display: none;
}

.speaker {
  flex: none;
  width: calc((100% - 1.5rem) / 3);
  scroll-snap-align: start;
  text-align: center;
}

.speaker img {
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: top;
  border: 1px solid var(--line);
  border-radius: 0.875rem;
  background: #fff;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.speaker:hover img {
  border-color: var(--ink);
  transform: translateY(-3px);
}

.speaker span {
  display: block;
  margin-top: 0.5rem;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.25;
}

/* Pagination dots (buttons are 24px tap targets; the dot is drawn inside) */
.dots {
  display: flex;
  justify-content: center;
  margin-top: 0.5rem;
}

.dot {
  display: grid;
  place-items: center;
  width: 1.5rem;
  height: 1.5rem;
}

.dot::before {
  content: '';
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 999px;
  background: rgba(23, 23, 23, 0.2);
  transition: width 0.3s ease, background-color 0.3s ease;
}

.dot:hover::before {
  background: rgba(23, 23, 23, 0.45);
}

.dot[aria-current='true']::before {
  width: 1.25rem;
  background: var(--ink);
}

/* Venue */
.venue-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  transition: background-color 0.2s ease;
}

.venue-row:hover {
  background: var(--cream);
}

.tips {
  display: grid;
  gap: 0.4rem;
  font-size: 0.8125rem;
}

.tips li {
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
}

.tips li::before {
  content: '';
  flex: none;
  width: 0.4rem;
  height: 0.4rem;
  background: var(--lit);
  transform: translateY(-0.1rem);
}

/* Chips */
.chip {
  padding: 0.45rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  font-size: 0.8125rem;
  font-weight: 600;
}

/* Live visit counter */
.visits {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.55rem 1rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  font-size: 0.875rem;
}

.count {
  display: inline-block;
  font-variant-numeric: tabular-nums;
}

.count.bump {
  animation: bump 0.45s ease;
}

.live-dot {
  position: relative;
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background: #16a34a;
}

.live-dot::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: inherit;
  animation: ping 1.6s cubic-bezier(0, 0, 0.2, 1) infinite;
}

.live-dot.is-off {
  background: #a3a3a3;
}

.live-dot.is-off::after {
  animation: none;
}

/* Toast */
.toast {
  position: fixed;
  left: 50%;
  bottom: 1.5rem;
  z-index: 50;
  padding: 0.6rem 1rem;
  border-radius: 999px;
  background: var(--ink);
  color: #fff;
  font-size: 0.8125rem;
  font-weight: 600;
  transform: translateX(-50%);
  animation: rise 0.25s ease both;
}

/* Entrance */
.reveal {
  animation: rise 0.5s ease both;
  animation-delay: calc(var(--i, 0) * 70ms);
}

@keyframes rise {
  from {
    opacity: 0;
    translate: 0 10px;
  }
}

@keyframes ping {
  75%,
  100% {
    transform: scale(2.4);
    opacity: 0;
  }
}

@keyframes bump {
  30% {
    transform: scale(1.2);
    color: var(--lit);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}

#nl-badge-frame,
iframe#nl-badge-frame,
iframe[id^="nl-badge"],
.nl-badge {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

/* Registration Modal & Form */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  background: rgba(23, 23, 23, 0.7);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.modal-backdrop.is-open {
  opacity: 1;
  visibility: visible;
}

.modal-card {
  position: relative;
  width: 100%;
  max-width: 28rem;
  max-height: 92vh;
  overflow-y: auto;
  background: #ffffff;
  border: 2px solid var(--ink);
  border-radius: 1.25rem;
  box-shadow: 6px 6px 0 var(--ink);
  padding: 1.5rem;
  transform: translateY(20px) scale(0.97);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-backdrop.is-open .modal-card {
  transform: translateY(0) scale(1);
}

.modal-close-btn {
  position: absolute;
  top: 1rem;
  right: 1rem;
  display: grid;
  place-items: center;
  width: 2.125rem;
  height: 2.125rem;
  border-radius: 999px;
  background: var(--cream);
  border: 1px solid var(--line);
  color: var(--ink);
  cursor: pointer;
  transition: transform 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
}

.modal-close-btn:hover {
  background: #fff;
  border-color: var(--ink);
  transform: rotate(90deg);
}

.form-group {
  margin-bottom: 0.85rem;
}

.form-label {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ink);
  margin-bottom: 0.35rem;
}

.form-input {
  width: 100%;
  padding: 0.65rem 0.875rem;
  font-size: 0.875rem;
  border: 1.5px solid var(--line);
  border-radius: 0.75rem;
  background: var(--cream);
  color: var(--ink);
  font-family: inherit;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.form-input:focus {
  outline: none;
  border-color: var(--ink);
  background: #ffffff;
  box-shadow: 2px 2px 0 var(--ink);
}

.form-input::placeholder {
  color: rgba(23, 23, 23, 0.4);
}

.form-input:user-invalid,
.form-input[aria-invalid='true'] {
  border-color: #dc2626;
  background: #fef2f2;
}

.form-error {
  margin-top: 0.35rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: #b91c1c;
}

.btn-submit {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.25rem;
  border-radius: 0.875rem;
  background: var(--lit);
  color: #fff;
  font-family: 'Anton', Impact, sans-serif;
  font-size: 1.125rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border: 2px solid var(--ink);
  box-shadow: 4px 4px 0 var(--ink);
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, opacity 0.15s ease;
}

.btn-submit:hover:not(:disabled) {
  transform: translate(-1px, -1px);
  box-shadow: 6px 6px 0 var(--ink);
}

.btn-submit:active:not(:disabled) {
  transform: translate(2px, 2px);
  box-shadow: 2px 2px 0 var(--ink);
}

.btn-submit:disabled {
  opacity: 0.75;
  cursor: not-allowed;
}



