/* ==========================================================================
   Likoma Airlines — Reset
   --------------------------------------------------------------------------
   A modern, opinionated baseline. Normalises the things that actually differ
   between engines and sets the few global defaults the design system relies
   on. It deliberately does *not* style typography — typography.css owns that.
   ========================================================================== */

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

* {
  margin: 0;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  -moz-tab-size: 4;
  tab-size: 4;
  scroll-behavior: smooth;
  /* Anchors and skip links must clear the sticky header */
  scroll-padding-top: calc(var(--header-height) + var(--space-6));
  height: 100%;
}

body {
  min-height: 100%;
  background-color: var(--color-background);
  color: var(--color-text-primary);
  font-family: var(--font-sans);
  font-size: var(--text-md);
  font-weight: var(--weight-regular);
  line-height: var(--leading-normal);
  letter-spacing: var(--tracking-normal);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  font-synthesis-weight: none;
  /* Prevent horizontal bleed from decorative, off-canvas hero elements */
  overflow-x: hidden;
}

/* Locks scroll behind modals and the mobile drawer without layout shift */
body[data-scroll-locked] {
  overflow: hidden;
  touch-action: none;
}

/* --- Headings & text ---------------------------------------------------- */

h1, h2, h3, h4, h5, h6 {
  font-size: inherit;
  font-weight: inherit;
  text-wrap: balance;
}

p, li, figcaption, dd {
  text-wrap: pretty;
}

/* Break long airport codes / URLs rather than overflow the container */
p, h1, h2, h3, h4, h5, h6, li, dt, dd, td, th, label, button, a {
  overflow-wrap: break-word;
}

/* --- Lists -------------------------------------------------------------- */

ul, ol {
  padding: 0;
}

/* Only strip semantics when the author opts in, so screen readers still
   announce genuine lists. */
ul[role="list"],
ol[role="list"],
ul[class],
ol[class] {
  list-style: none;
}

/* --- Media -------------------------------------------------------------- */

img, picture, video, canvas, svg, iframe {
  display: block;
  max-width: 100%;
}

img, video {
  height: auto;
}

img {
  font-style: italic;   /* styles the alt text if the file 404s */
  color: var(--color-text-muted);
  vertical-align: middle;
}

/* Placeholder tint while a lazy image decodes, so photography does not flash
   white on arrival. Scoped to photographic contexts only — as a blanket rule
   on `img` it paints a grey box behind every transparent logo and icon. */
.lk-media img,
.lk-card__media img,
.lk-destination img,
.lk-experience__media img,
.lk-cabin__media img,
img[data-placeholder] {
  background-color: var(--navy-100);
}

svg {
  fill: currentColor;
  flex-shrink: 0;
}

/* --- Forms -------------------------------------------------------------- */

input, button, textarea, select, optgroup {
  font: inherit;
  letter-spacing: inherit;
  color: inherit;
  background: none;
  border: none;
}

button, [role="button"], summary, label[for], select {
  cursor: pointer;
}

button {
  padding: 0;
  text-align: inherit;
  -webkit-tap-highlight-color: transparent;
}

textarea {
  resize: vertical;
  min-height: 6rem;
}

/* Clear the native decorations we replace with our own */
input[type="search"]::-webkit-search-decoration,
input[type="search"]::-webkit-search-cancel-button,
input[type="search"]::-webkit-search-results-button,
input[type="search"]::-webkit-search-results-decoration {
  -webkit-appearance: none;
  appearance: none;
}

input[type="number"] {
  -moz-appearance: textfield;
  appearance: textfield;
}

input[type="number"]::-webkit-outer-spin-button,
input[type="number"]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  appearance: none;
  margin: 0;
}

::placeholder {
  color: var(--color-text-muted);
  opacity: 1;
}

:disabled,
[aria-disabled="true"] {
  cursor: not-allowed;
}

fieldset {
  padding: 0;
  border: 0;
  min-inline-size: 0;
}

legend {
  padding: 0;
}

/* --- Links -------------------------------------------------------------- */

a {
  color: inherit;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
}

/* Underlines belong in prose, not in navigation */
.prose a,
a.lk-link {
  color: var(--color-text-link);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
  text-decoration-color: color-mix(in srgb, currentColor 35%, transparent);
  transition: var(--transition-colors), text-decoration-color var(--duration-fast) var(--ease-soft);
}

.prose a:hover,
a.lk-link:hover {
  color: var(--color-text-link-hover);
  text-decoration-color: currentColor;
}

/* --- Tables ------------------------------------------------------------- */

table {
  border-collapse: collapse;
  border-spacing: 0;
  width: 100%;
}

th {
  text-align: left;
  font-weight: var(--weight-medium);
}

/* --- Misc --------------------------------------------------------------- */

hr {
  border: 0;
  border-top: 1px solid var(--color-divider);
  height: 0;
}

address {
  font-style: normal;
}

abbr[title] {
  text-decoration: underline dotted;
  cursor: help;
}

dialog {
  padding: 0;
  border: 0;
  max-width: none;
  max-height: none;
  background: transparent;
  color: inherit;
}

dialog::backdrop {
  background-color: var(--color-overlay);
}

summary {
  list-style: none;
}

summary::-webkit-details-marker {
  display: none;
}

[hidden] {
  display: none !important;
}

/* --- Selection & scrollbars --------------------------------------------- */

::selection {
  background-color: var(--color-selection-bg);
  color: var(--color-selection-fg);
}

@supports (scrollbar-width: thin) {
  .lk-scroll-thin {
    scrollbar-width: thin;
    scrollbar-color: var(--color-border-strong) transparent;
  }
}

.lk-scroll-thin::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

.lk-scroll-thin::-webkit-scrollbar-track {
  background: transparent;
}

.lk-scroll-thin::-webkit-scrollbar-thumb {
  background-color: var(--color-border-strong);
  border-radius: var(--radius-full);
}

/* --- Focus -------------------------------------------------------------- */

/* Never remove focus outright — only trade the default ring for ours. */
:focus {
  outline: none;
}

:focus-visible {
  outline: 2px solid var(--color-focus-ring);
  outline-offset: 2px;
  border-radius: var(--radius-xs);
}

/* --- Motion preferences -------------------------------------------------- */

@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;
    scroll-behavior: auto !important;
  }
}

/* --- Print --------------------------------------------------------------- */

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

  a[href^="http"]::after {
    content: " (" attr(href) ")";
    font-size: 0.85em;
    word-break: break-all;
  }

  .lk-header,
  .lk-footer,
  .lk-drawer,
  .lk-toast-region,
  [data-print="hide"] {
    display: none !important;
  }
}
