/**
 * Tokyo Hero v0.2 — New Nomads Edition
 * Global CSS: dark-first token bridge, resets, components
 *
 * Architecture:
 *   1.  Semantic token bridge (--th-* aliases)
 *   2.  CSS reset & base
 *   3.  Typography utilities
 *   4.  Buttons
 *   5.  Form elements
 *   6.  Navigation
 *   7.  Cards (dark, rounded)
 *   8.  Hero
 *   9.  Status / feedback
 *   10. Animations
 *   11. Accessibility utilities
 *   12. Block overrides
 *   13. Custom block styles
 *   14. Header scroll state
 *   15. Tour card interactions
 *   16. Search results
 *   17. Newsletter form
 *   18. Pagination
 *   19. Print
 */

/* ═══════════════════════════════════════════════════════════════
   1. SEMANTIC TOKEN BRIDGE
   ═══════════════════════════════════════════════════════════════ */

:root {
  /* Surface */
  --th-surface:          var(--wp--preset--color--surface-default);
  --th-surface-2:        var(--wp--preset--color--surface-secondary);
  --th-surface-elevated: var(--wp--preset--color--surface-elevated);
  --th-surface-raised:   var(--wp--preset--color--surface-raised);
  --th-surface-overlay:  var(--wp--preset--color--surface-overlay);
  --th-surface-light:    var(--wp--preset--color--surface-light);

  /* Text */
  --th-text:             var(--wp--preset--color--text-primary);
  --th-text-2:           var(--wp--preset--color--text-secondary);
  --th-text-muted:       var(--wp--preset--color--text-muted);
  --th-text-on-light:    var(--wp--preset--color--text-on-light);
  --th-text-link:        var(--wp--preset--color--text-link);
  --th-text-link-hover:  var(--wp--preset--color--text-link-hover);

  /* Interactive */
  --th-brand:            var(--wp--preset--color--interactive-brand);
  --th-brand-hover:      var(--wp--preset--color--interactive-brand-hover);
  --th-brand-active:     var(--wp--preset--color--interactive-brand-active);
  --th-accent:           var(--wp--preset--color--interactive-accent);
  --th-accent-hover:     var(--wp--preset--color--interactive-accent-hover);
  --th-accent-active:    var(--wp--preset--color--interactive-accent-active);
  --th-accent-dim:       var(--wp--preset--color--interactive-accent-dim);

  /* Border */
  --th-border:           var(--wp--preset--color--border-default);
  --th-border-strong:    var(--wp--preset--color--border-strong);
  --th-border-subtle:    var(--wp--preset--color--border-subtle);
  --th-border-accent:    var(--wp--preset--color--border-accent);

  /* Status */
  --th-success:          var(--wp--preset--color--status-success);
  --th-success-surface:  var(--wp--preset--color--status-success-surface);
  --th-warning:          var(--wp--preset--color--status-warning);
  --th-warning-surface:  var(--wp--preset--color--status-warning-surface);
  --th-error:            var(--wp--preset--color--status-error);
  --th-error-surface:    var(--wp--preset--color--status-error-surface);

  /* Typography */
  --th-font-display: var(--wp--preset--font-family--display);
  --th-font-body:    var(--wp--preset--font-family--body);
  --th-font-mono:    var(--wp--preset--font-family--mono);

  /* Radius — component tokens */
  --th-radius-sm:   0.375rem;
  --th-radius:      0.75rem;
  --th-radius-lg:   1rem;
  --th-radius-xl:   1.25rem;
  --th-radius-2xl:  1.5rem;
  --th-radius-full: 9999px;

  /* Shadows */
  --th-shadow-sm:          var(--wp--preset--shadow--sm);
  --th-shadow-md:          var(--wp--preset--shadow--md);
  --th-shadow-lg:          var(--wp--preset--shadow--lg);
  --th-shadow-xl:          var(--wp--preset--shadow--xl);
  --th-shadow-card:        var(--wp--preset--shadow--card);
  --th-shadow-card-hover:  var(--wp--preset--shadow--card-hover);
  --th-shadow-accent-glow: var(--wp--preset--shadow--accent-glow);
  --th-shadow-brand-glow:  var(--wp--preset--shadow--brand-glow);
  --th-shadow-accent-halo: var(--wp--preset--shadow--accent-halo);

  /* Transitions */
  --th-transition-fast:   120ms ease;
  --th-transition-base:   220ms ease;
  --th-transition-slow:   380ms ease;
  --th-transition-spring: 420ms cubic-bezier(0.34, 1.56, 0.64, 1);

  /* Component tokens */
  --th-btn-accent-bg:          var(--th-accent);
  --th-btn-accent-bg-hover:    var(--th-accent-hover);
  --th-btn-accent-text:        var(--th-surface);
  --th-btn-brand-bg:           var(--th-brand);
  --th-btn-brand-bg-hover:     var(--th-brand-hover);
  --th-btn-brand-text:         var(--th-surface-light);
  --th-btn-ghost-border:       var(--th-border-strong);
  --th-btn-ghost-text:         var(--th-text-2);
  --th-btn-ghost-bg-hover:     var(--th-surface-elevated);
  --th-card-bg:                var(--th-surface-elevated);
  --th-card-border:            var(--th-border);
  --th-card-radius:            var(--th-radius-lg);
  --th-card-shadow:            var(--th-shadow-card);
  --th-card-shadow-hover:      var(--th-shadow-card-hover);
  --th-input-bg:               var(--th-surface-elevated);
  --th-input-border:           var(--th-border-strong);
  --th-input-border-focus:     var(--th-accent);
  --th-input-text:             var(--th-text);
  --th-input-placeholder:      var(--th-text-muted);
  --th-input-radius:           var(--th-radius);
  --th-focus-ring-width:       2px;
  --th-focus-ring-offset:      3px;
  --th-focus-ring-color:       var(--th-accent);
}

/* ═══════════════════════════════════════════════════════════════
   2. RESET & BASE
   ═══════════════════════════════════════════════════════════════ */

*,
*::before,
*::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  text-size-adjust: 100%;
  hanging-punctuation: first last;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  background-color: var(--th-surface);
  color: var(--th-text);
  font-family: var(--th-font-body);
  font-size: var(--wp--preset--font-size--base);
  line-height: 1.60;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizelegibility;
}

img,
video,
svg {
  display: block;
  max-width: 100%;
  height: auto;
}

p,
h1,
h2,
h3,
h4,
h5,
h6 { overflow-wrap: break-word; }

/* ═══════════════════════════════════════════════════════════════
   3. TYPOGRAPHY UTILITIES
   ═══════════════════════════════════════════════════════════════ */

.th-display {
  font-family: var(--th-font-display);
  line-height: 1.00;
  letter-spacing: -0.01em;
  text-transform: uppercase;
}

.th-eyebrow {
  display: flex;
  align-items: center;
  gap: var(--wp--preset--spacing--3);
  font-family: var(--th-font-body);
  font-size: var(--wp--preset--font-size--xs);
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--th-accent);
}

.th-eyebrow::before {
  content: '';
  display: inline-block;
  width: 1.75rem;
  height: 2px;
  background-color: currentcolor;
  flex-shrink: 0;
  border-radius: var(--th-radius-full);
}

.th-label {
  font-family: var(--th-font-body);
  font-size: var(--wp--preset--font-size--xs);
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

/* ═══════════════════════════════════════════════════════════════
   4. BUTTONS
   ═══════════════════════════════════════════════════════════════ */

.wp-block-button .wp-block-button__link,
.wp-element-button {
  display: inline-flex;
  align-items: center;
  gap: var(--wp--preset--spacing--2);
  font-family: var(--th-font-body);
  font-size: var(--wp--preset--font-size--sm);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-decoration: none;
  text-transform: uppercase;
  padding: 0.75rem 1.75rem;
  border-radius: var(--th-radius);
  border: 2px solid transparent;
  cursor: pointer;
  transition:
    background-color var(--th-transition-base),
    border-color     var(--th-transition-base),
    color            var(--th-transition-base),
    box-shadow       var(--th-transition-base),
    transform        var(--th-transition-fast);
}

.wp-block-button .wp-block-button__link:focus-visible,
.wp-element-button:focus-visible {
  outline: var(--th-focus-ring-width) solid var(--th-focus-ring-color);
  outline-offset: var(--th-focus-ring-offset);
}

.wp-block-button .wp-block-button__link:active,
.wp-element-button:active { transform: translateY(1px); }

/* Default = accent (orange) */
.wp-block-button:not(.is-style-brand, .is-style-outline, .is-style-outline-brand, .is-style-ghost) .wp-block-button__link {
  background-color: var(--th-btn-accent-bg);
  color:            var(--th-btn-accent-text);
  border-color:     var(--th-btn-accent-bg);
}

.wp-block-button:not(.is-style-brand, .is-style-outline, .is-style-outline-brand, .is-style-ghost) .wp-block-button__link:hover {
  background-color: var(--th-btn-accent-bg-hover);
  border-color:     var(--th-btn-accent-bg-hover);
  box-shadow: var(--th-shadow-accent-halo);
}

/* Brand (blue) */
.wp-block-button.is-style-brand .wp-block-button__link {
  background-color: var(--th-btn-brand-bg);
  color:            var(--th-btn-brand-text);
  border-color:     var(--th-btn-brand-bg);
}

.wp-block-button.is-style-brand .wp-block-button__link:hover {
  background-color: var(--th-btn-brand-bg-hover);
  border-color:     var(--th-btn-brand-bg-hover);
  box-shadow: var(--th-shadow-brand-glow);
}

/* Outline accent */
.wp-block-button.is-style-outline .wp-block-button__link {
  background-color: transparent;
  color:            var(--th-accent);
  border-color:     var(--th-accent);
}

.wp-block-button.is-style-outline .wp-block-button__link:hover {
  background-color: var(--th-accent);
  color:            var(--th-surface);
}

/* Outline brand */
.wp-block-button.is-style-outline-brand .wp-block-button__link {
  background-color: transparent;
  color:            var(--th-brand-hover);
  border-color:     var(--th-brand);
}

.wp-block-button.is-style-outline-brand .wp-block-button__link:hover {
  background-color: var(--th-brand);
  color:            var(--th-surface-light);
}

/* Ghost */
.wp-block-button.is-style-ghost .wp-block-button__link {
  background-color: transparent;
  color:            var(--th-btn-ghost-text);
  border-color:     var(--th-btn-ghost-border);
}

.wp-block-button.is-style-ghost .wp-block-button__link:hover {
  background-color: var(--th-btn-ghost-bg-hover);
  color:            var(--th-text);
}

/* ═══════════════════════════════════════════════════════════════
   5. FORM ELEMENTS
   ═══════════════════════════════════════════════════════════════ */

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="url"],
input[type="search"],
input[type="password"],
input[type="number"],
textarea,
select {
  background-color: var(--th-input-bg);
  border: 1.5px solid var(--th-input-border);
  border-radius: var(--th-input-radius);
  color: var(--th-input-text);
  font-family: var(--th-font-body);
  font-size: var(--wp--preset--font-size--base);
  line-height: 1.5;
  padding: 0.625rem 0.875rem;
  width: 100%;
  transition:
    border-color var(--th-transition-base),
    box-shadow   var(--th-transition-base);
  appearance: none;
}

input::placeholder,
textarea::placeholder { color: var(--th-input-placeholder); }

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--th-input-border-focus);
  box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.25);
}

input[aria-invalid="true"],
textarea[aria-invalid="true"] { border-color: var(--th-error); }

input[aria-invalid="true"]:focus,
textarea[aria-invalid="true"]:focus {
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.25);
}

label {
  display: block;
  font-size: var(--wp--preset--font-size--sm);
  font-weight: 600;
  color: var(--th-text-2);
  margin-block-end: var(--wp--preset--spacing--2);
  letter-spacing: 0.04em;
}

/* ═══════════════════════════════════════════════════════════════
   6. NAVIGATION
   ═══════════════════════════════════════════════════════════════ */

.wp-block-navigation-item__content {
  color: inherit;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-decoration: none;
  padding-block: 0.25rem;
  position: relative;
  transition: color var(--th-transition-base);
}

.wp-block-navigation-item__content::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  right: 100%;
  height: 2px;
  background-color: var(--th-accent);
  border-radius: var(--th-radius-full);
  transition: right var(--th-transition-base);
}

.wp-block-navigation-item__content:hover::after,
.wp-block-navigation-item.current-menu-item > .wp-block-navigation-item__content::after {
  right: 0;
}

.wp-block-navigation-item__content:focus-visible {
  outline: var(--th-focus-ring-width) solid var(--th-focus-ring-color);
  outline-offset: var(--th-focus-ring-offset);
  border-radius: var(--th-radius-sm);
}

/* ═══════════════════════════════════════════════════════════════
   7. CARDS
   ═══════════════════════════════════════════════════════════════ */

.th-card {
  background-color: var(--th-card-bg);
  border: 1px solid var(--th-card-border);
  border-radius: var(--th-card-radius);
  box-shadow: var(--th-card-shadow);
  overflow: hidden;
  transition:
    box-shadow var(--th-transition-slow),
    transform  var(--th-transition-slow),
    border-color var(--th-transition-slow);
}

.th-card:hover {
  box-shadow: var(--th-card-shadow-hover);
  transform: translateY(-4px);
  border-color: rgba(249, 115, 22, 0.20);
}

.th-card__image {
  aspect-ratio: 4/3;
  overflow: hidden;
}

.th-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--th-transition-slow);
}

.th-card:hover .th-card__image img { transform: scale(1.05); }

.th-card__body { padding: var(--wp--preset--spacing--6); }

.th-card__tag {
  display: inline-flex;
  align-items: center;
  font-size: var(--wp--preset--font-size--2xs);
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--th-accent);
  margin-block-end: var(--wp--preset--spacing--3);
}

.th-card__title {
  font-family: var(--th-font-display);
  font-size: var(--wp--preset--font-size--3xl);
  font-weight: 400;
  line-height: 1.10;
  letter-spacing: -0.01em;
  color: var(--th-text);
  margin-block-end: var(--wp--preset--spacing--3);
  text-transform: uppercase;
}

.th-card__excerpt {
  font-size: var(--wp--preset--font-size--sm);
  color: var(--th-text-2);
  line-height: 1.65;
}

/* ═══════════════════════════════════════════════════════════════
   8. HERO
   ═══════════════════════════════════════════════════════════════ */

.th-hero {
  position: relative;
  min-height: 90svh;
  display: grid;
  place-items: end start;
  overflow: hidden;
}

.th-hero__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.th-hero__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.th-hero__overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(
    175deg,
    rgba(10, 12, 15, 0.15) 0%,
    rgba(10, 12, 15, 0.60) 50%,
    rgba(10, 12, 15, 0.92) 100%
  );
}

.th-hero__content {
  position: relative;
  z-index: 2;
  padding: var(--wp--preset--spacing--20) var(--wp--preset--spacing--8);
  max-width: 1000px;
}

.th-hero__title {
  font-family: var(--th-font-display);
  font-size: clamp(4rem, 10vw, 9rem);
  font-weight: 400;
  line-height: 0.95;
  letter-spacing: -0.01em;
  text-transform: uppercase;
  color: var(--th-surface-light);
  margin-block-end: var(--wp--preset--spacing--6);
}

.th-hero__subtitle {
  font-size: var(--wp--preset--font-size--lg);
  color: var(--th-text-2);
  max-width: 540px;
  line-height: 1.65;
  margin-block-end: var(--wp--preset--spacing--10);
}

/* ═══════════════════════════════════════════════════════════════
   9. STATUS / FEEDBACK
   ═══════════════════════════════════════════════════════════════ */

.th-alert {
  display: flex;
  align-items: flex-start;
  gap: var(--wp--preset--spacing--3);
  padding: var(--wp--preset--spacing--4) var(--wp--preset--spacing--5);
  border-radius: var(--th-radius);
  border-left: 3px solid;
  font-size: var(--wp--preset--font-size--sm);
  line-height: 1.55;
}

.th-alert__icon {
  flex-shrink: 0;
  width: 1.25rem;
  height: 1.25rem;
  margin-top: 0.05rem;
}

.th-alert--success {
  background-color: var(--th-success-surface);
  border-color:     var(--th-success);
  color:            #4ade80;
}

.th-alert--warning {
  background-color: var(--th-warning-surface);
  border-color:     var(--th-warning);
  color:            #fbbf24;
}

.th-alert--error {
  background-color: var(--th-error-surface);
  border-color:     var(--th-error);
  color:            #f87171;
}

/* Skeleton loader */
.th-skeleton {
  background: linear-gradient(
    90deg,
    var(--th-surface-2) 25%,
    var(--th-surface-elevated) 50%,
    var(--th-surface-2) 75%
  );
  background-size: 400% 100%;
  animation: th-skeleton-shimmer 1.4s ease infinite;
  border-radius: var(--th-radius-sm);
}

@keyframes th-skeleton-shimmer {
  0% {
    background-position: 100% 50%;
  }

  100% {
    background-position: 0% 50%;
  }
}

/* ═══════════════════════════════════════════════════════════════
   10. ANIMATIONS
   ═══════════════════════════════════════════════════════════════ */

@keyframes th-fade-up {
  from {
    opacity: 0;
    transform: translateY(1.5rem);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes th-fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes th-scale-in {
  from {
    opacity: 0;
    transform: scale(0.94);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes th-glow-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(249, 115, 22, 0); }
  50%       { box-shadow: 0 0 20px 4px rgba(249, 115, 22, 0.25); }
}

.th-animate-fade-up {
  animation: th-fade-up 0.6s ease forwards;
  opacity: 0;
}

.th-animate-fade-in {
  animation: th-fade-in 0.5s ease forwards;
  opacity: 0;
}

.th-animate-glow-pulse {
  animation: th-glow-pulse 2.4s ease infinite;
}

.th-delay-1 { animation-delay: 0.10s; }
.th-delay-2 { animation-delay: 0.20s; }
.th-delay-3 { animation-delay: 0.30s; }
.th-delay-4 { animation-delay: 0.40s; }
.th-delay-5 { animation-delay: 0.55s; }

/* ═══════════════════════════════════════════════════════════════
   11. ACCESSIBILITY UTILITIES
   ═══════════════════════════════════════════════════════════════ */

.screen-reader-text,
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: -100%;
  left: var(--wp--preset--spacing--4);
  z-index: 9999;
  background-color: var(--th-accent);
  color: var(--th-surface);
  padding: 0.75rem 1.25rem;
  font-weight: 700;
  font-size: var(--wp--preset--font-size--sm);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border-radius: 0 0 var(--th-radius) var(--th-radius);
  text-decoration: none;
  transition: top var(--th-transition-fast);
}

.skip-link:focus {
  top: 0;
  outline: var(--th-focus-ring-width) solid var(--th-surface-light);
  outline-offset: var(--th-focus-ring-offset);
}

:focus-visible {
  outline: var(--th-focus-ring-width) solid var(--th-focus-ring-color);
  outline-offset: var(--th-focus-ring-offset);
  border-radius: var(--th-radius-sm);
}

:focus:not(:focus-visible) { outline: none; }

/* ═══════════════════════════════════════════════════════════════
   12. BLOCK OVERRIDES
   ═══════════════════════════════════════════════════════════════ */

.wp-block-cover { min-height: 70svh; }

.wp-block-separator {
  border-color: var(--th-border);
  opacity: 1;
}

.wp-block-table td,
.wp-block-table th {
  border-color: var(--th-border-strong);
  padding: var(--wp--preset--spacing--3) var(--wp--preset--spacing--4);
}

.wp-block-table thead {
  background-color: var(--th-surface-2);
  font-weight: 600;
}

.wp-block-post-navigation-link a {
  color: var(--th-accent);
  text-decoration: none;
  font-weight: 500;
  transition: color var(--th-transition-base);
}

.wp-block-post-navigation-link a:hover { color: var(--th-accent-hover); }

.wp-block-tag-cloud a {
  display: inline-block;
  padding: 0.25rem 0.875rem;
  border: 1px solid var(--th-border-strong);
  border-radius: var(--th-radius-full);
  font-size: var(--wp--preset--font-size--xs) !important;
  font-weight: 500;
  color: var(--th-text-2);
  text-decoration: none;
  transition:
    border-color     var(--th-transition-base),
    color            var(--th-transition-base),
    background-color var(--th-transition-base);
}

.wp-block-tag-cloud a:hover {
  border-color:     var(--th-accent);
  color:            var(--th-accent);
  background-color: rgba(249, 115, 22, 0.08);
}

/* ═══════════════════════════════════════════════════════════════
   13. CUSTOM BLOCK STYLE VARIANTS
   ═══════════════════════════════════════════════════════════════ */

.wp-block-image.is-style-th-rounded img { border-radius: var(--th-card-radius); }

.wp-block-group.is-style-th-surface-elevated {
  background-color: var(--th-surface-elevated);
  border-radius:    var(--th-radius-xl);
  border:           1px solid var(--th-border);
}

.wp-block-group.is-style-th-surface-raised {
  background-color: var(--th-surface-raised);
  border-radius:    var(--th-radius-xl);
  border:           1px solid var(--th-border);
}

/* ═══════════════════════════════════════════════════════════════
   14. HEADER SCROLL STATE
   ═══════════════════════════════════════════════════════════════ */

.wp-block-template-part[data-area="header"].is-scrolled {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: rgba(15, 17, 23, 0.92);
  backdrop-filter: blur(16px);
  box-shadow: 0 1px 0 var(--th-border-subtle);
}

/* ═══════════════════════════════════════════════════════════════
   15. TOUR CARD INTERACTIONS
   ═══════════════════════════════════════════════════════════════ */

.th-tour-card {
  position: relative;
  overflow: hidden;
  cursor: pointer;
  border-radius: var(--th-radius-lg);
  background-color: var(--th-surface-elevated);
}

.th-tour-card .th-tour-card__overlay {
  transition: background var(--th-transition-slow);
}

.th-tour-card:hover .th-tour-card__overlay {
  background: linear-gradient(180deg, transparent 15%, rgba(10, 12, 15, 0.98) 100%) !important;
}

.th-tour-card img {
  transition: transform var(--th-transition-slow);
  transform-origin: center;
}

.th-tour-card:hover img { transform: scale(1.06); }

/* ═══════════════════════════════════════════════════════════════
   16. SEARCH RESULTS
   ═══════════════════════════════════════════════════════════════ */

.th-search-result {
  padding-bottom: var(--wp--preset--spacing--8);
  border-bottom: 1px solid var(--th-border);
}

.th-search-result + .th-search-result {
  padding-top: var(--wp--preset--spacing--8);
}

/* ═══════════════════════════════════════════════════════════════
   17. NEWSLETTER FORM
   ═══════════════════════════════════════════════════════════════ */

.th-newsletter-form input[type="email"] {
  background-color: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.15);
  color: var(--th-text);
  border-radius: var(--th-radius);
}

.th-newsletter-form input[type="email"]:focus {
  outline: none;
  border-color: var(--th-accent);
  box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.25);
}

.th-newsletter-form input[type="email"]::placeholder { color: var(--th-text-muted); }

.th-newsletter-form button[type="submit"]:hover {
  background-color: var(--th-accent-hover) !important;
}

.th-newsletter-form button[type="submit"]:focus-visible {
  outline: 2px solid var(--th-surface-light);
  outline-offset: 3px;
}

/* ═══════════════════════════════════════════════════════════════
   18. PAGINATION
   ═══════════════════════════════════════════════════════════════ */

.wp-block-query-pagination {
  display: flex;
  align-items: center;
  gap: var(--wp--preset--spacing--2);
  flex-wrap: wrap;
}

.wp-block-query-pagination-numbers .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--th-radius);
  border: 1.5px solid var(--th-border-strong);
  color: var(--th-text-2);
  text-decoration: none;
  font-size: var(--wp--preset--font-size--sm);
  font-weight: 500;
  transition:
    border-color     var(--th-transition-base),
    background-color var(--th-transition-base),
    color            var(--th-transition-base);
}

.wp-block-query-pagination-numbers .page-numbers:hover {
  border-color: var(--th-accent);
  color: var(--th-accent);
  background-color: rgba(249, 115, 22, 0.08);
}

.wp-block-query-pagination-numbers .page-numbers.current {
  background-color: var(--th-accent);
  border-color:     var(--th-accent);
  color:            var(--th-surface);
  font-weight: 700;
}

.wp-block-query-pagination-previous,
.wp-block-query-pagination-next {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 1rem;
  border-radius: var(--th-radius);
  border: 1.5px solid var(--th-border-strong);
  color: var(--th-text-2);
  text-decoration: none;
  font-size: var(--wp--preset--font-size--sm);
  font-weight: 500;
  transition:
    border-color var(--th-transition-base),
    color        var(--th-transition-base);
}

.wp-block-query-pagination-previous:hover,
.wp-block-query-pagination-next:hover {
  border-color: var(--th-accent);
  color: var(--th-accent);
}

/* ═══════════════════════════════════════════════════════════════
   19. PRINT
   ═══════════════════════════════════════════════════════════════ */

@media print {
  *,
  *::before,
  *::after {
    background: transparent !important;
    color: #000 !important;
    box-shadow: none !important;
    text-shadow: none !important;
  }

  a[href]::after { content: " (" attr(href) ")"; }

  img {
    max-width: 100% !important;
    break-inside: avoid;
  }

  h2,
  h3 {
    break-after: avoid;
  }

  p {
    orphans: 3;
    widows: 3;
  }

  .wp-block-navigation,
  .th-hero,
  footer { display: none !important; }
}
