/* XONE by ACICOR: the one palette and the glass controls for every page.
   Plain CSS, not Tailwind, so the full-screen pages that carry their own <style>
   (Cursos, Comprar, Vacantes, Talento, Postulaciones, the top bar) read the same values
   as the Tailwind build. The Tailwind theme in app/assets/tailwind/application.css mirrors these. */

/* Same layer order Tailwind declares, so a utility class (hidden, w-full) still beats these. */
@layer theme, base, components, utilities;

:root {
  /* Brand palette, from the XONE brand sheet. */
  --x-sky: #00c2ff;      /* Azul cielo: trust, technology */
  --x-violet: #8a3dff;   /* Violeta: creativity, innovation */
  --x-magenta: #e546ff;  /* Magenta: energy, people */
  --x-night: #0b0f1a;    /* Negro profundo: text and dark surfaces */

  /* Working surfaces. The names match the old tokens so existing classes keep their meaning. */
  --x-ink: #0b0f1a;
  --x-muted: #6b7088;
  --x-line: #e3e5f0;
  --x-paper: #f3f4fa;
  --x-cream: #f7f8fc;
  --x-white: #ffffff;

  --x-gradient: linear-gradient(100deg, var(--x-sky) 0%, var(--x-violet) 55%, var(--x-magenta) 100%);
  --x-gradient-soft: linear-gradient(120deg, rgba(0, 194, 255, .14), rgba(138, 61, 255, .12) 55%, rgba(229, 70, 255, .14));
  --x-focus: 0 0 0 3px rgba(138, 61, 255, .28);

  --x-font-display: "Montserrat", "Inter", ui-sans-serif, system-ui, sans-serif;
  --x-font-body: "Inter", ui-sans-serif, system-ui, sans-serif;

  /* Light page. Stops a Mac in Dark Mode from restyling native controls. */
  color-scheme: light;
}

@layer components {
  /* Primary action: the gradient glass pill from the XONE pieces.
     A top highlight and an inner rim give the glass; the glow carries the violet. */
  .x-btn,
  .x-btn-glass {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .6em;
    border-radius: 999px;
    font-family: var(--x-font-body);
    font-weight: 650;
    line-height: 1.2;
    text-decoration: none;
    cursor: pointer;
    isolation: isolate;
    /* Safari keeps the system button chrome unless appearance is none, so the pill
       loses its radius and the label clips. Chrome already follows the author background. */
    -webkit-appearance: none;
    appearance: none;
    transition: transform .15s ease, box-shadow .2s ease, background-color .2s ease, filter .2s ease;
  }

  .x-btn {
    /* The shine is a ::before. Glass buttons must not clip, or Safari drops their blur. */
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, .35);
    background: var(--x-gradient);
    color: #fff;
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, .55),
      inset 0 -8px 16px rgba(11, 15, 26, .12),
      0 8px 22px rgba(138, 61, 255, .30);
  }

  /* The glass shine: a soft light that fades down from the top edge. It has no shape of its own,
     so a label on two lines never shows it as a second button behind. */
  .x-btn::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    border-radius: inherit;
    background: linear-gradient(180deg, rgba(255, 255, 255, .34) 0, rgba(255, 255, 255, .1) 22px, rgba(255, 255, 255, 0) 30px);
    pointer-events: none;
  }

  .x-btn:hover {
    filter: saturate(1.15) brightness(1.04);
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, .6),
      inset 0 -8px 16px rgba(11, 15, 26, .12),
      0 10px 28px rgba(138, 61, 255, .42);
  }

  /* Secondary action: frosted glass. Ink text on light pages, white text on dark ones (.x-on-dark). */
  .x-btn-glass {
    border: 1px solid rgba(255, 255, 255, .85);
    background: rgba(255, 255, 255, .55);
    color: var(--x-ink);
    -webkit-backdrop-filter: blur(14px) saturate(1.4);
    backdrop-filter: blur(14px) saturate(1.4);
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, .9),
      0 0 0 1px var(--x-line),
      0 6px 18px rgba(11, 15, 26, .06);
  }

  .x-btn-glass:hover {
    background: rgba(255, 255, 255, .8);
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, .9),
      0 0 0 1px rgba(138, 61, 255, .35),
      0 8px 22px rgba(138, 61, 255, .14);
  }

  .x-on-dark .x-btn-glass,
  .x-btn-glass.x-on-dark {
    border-color: rgba(255, 255, 255, .28);
    background: rgba(255, 255, 255, .10);
    color: #fff;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25), 0 6px 18px rgba(0, 0, 0, .2);
  }

  .x-on-dark .x-btn-glass:hover,
  .x-btn-glass.x-on-dark:hover {
    background: rgba(255, 255, 255, .18);
  }

  .x-btn:active,
  .x-btn-glass:active { transform: translateY(1px); }

  .x-btn:focus-visible,
  .x-btn-glass:focus-visible {
    outline: none;
    box-shadow: var(--x-focus);
  }

  .x-btn[disabled],
  .x-btn-glass[disabled],
  .x-btn[aria-disabled="true"],
  .x-btn-glass[aria-disabled="true"] {
    cursor: not-allowed;
    opacity: .55;
    filter: grayscale(.3);
  }

  /* A glass card, for the few surfaces that sit over a picture or the gradient. */
  .x-glass {
    border: 1px solid rgba(255, 255, 255, .8);
    background: rgba(255, 255, 255, .62);
    -webkit-backdrop-filter: blur(18px) saturate(1.3);
    backdrop-filter: blur(18px) saturate(1.3);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .9), 0 12px 32px rgba(11, 15, 26, .08);
  }

  /* Words in the brand gradient, the way "Todas las conexiones." is set in the pieces. */
  .x-gradient-text {
    background: var(--x-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
  }

  /* The short gradient rule under a section label. */
  .x-rule {
    display: block;
    width: 48px;
    height: 3px;
    border-radius: 3px;
    background: var(--x-gradient);
  }

  /* Glass chip with an icon tile, as "Certificación", "Vigencia", "Renovación" in the pieces:
     frosted white, a soft tinted square holding a violet icon, an ink label. */
  .x-chip {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 8px 18px 8px 8px;
    border: 1px solid rgba(255, 255, 255, .9);
    border-radius: 18px;
    background: rgba(255, 255, 255, .68);
    -webkit-backdrop-filter: blur(16px) saturate(1.4);
    backdrop-filter: blur(16px) saturate(1.4);
    box-shadow: inset 0 1px 0 #fff, 0 0 0 1px rgba(138, 61, 255, .08), 0 10px 28px rgba(92, 64, 190, .12);
    color: var(--x-ink);
    font-family: var(--x-font-body);
    font-weight: 650;
    line-height: 1.2;
    text-decoration: none;
    transition: box-shadow .2s ease, transform .15s ease;
  }

  a.x-chip:hover,
  button.x-chip:hover {
    box-shadow: inset 0 1px 0 #fff, 0 0 0 1px rgba(138, 61, 255, .3), 0 12px 30px rgba(138, 61, 255, .18);
  }

  .x-chip-icon {
    display: grid;
    flex: none;
    place-items: center;
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: linear-gradient(140deg, rgba(0, 194, 255, .14), rgba(138, 61, 255, .14) 60%, rgba(229, 70, 255, .12));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .9);
    color: var(--x-violet);
  }

  .x-chip-icon svg { width: 22px; height: 22px; }

  /* Small glass chip without an icon, for a course code or a filter. */
  .x-chip-sm {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    border: 1px solid rgba(255, 255, 255, .9);
    border-radius: 999px;
    background: rgba(255, 255, 255, .72);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    box-shadow: inset 0 1px 0 #fff, 0 0 0 1px var(--x-line), 0 4px 12px rgba(92, 64, 190, .08);
    color: var(--x-ink);
    font-size: 14px;
    font-weight: 700;
    line-height: 1.2;
    text-decoration: none;
    transition: box-shadow .2s ease, color .2s ease;
  }

  /* Tinted glass tile with a round icon, as "Cursos", "Rutas", "Actualización" in the pieces.
     The tint comes from the modifier; hover or the current one turns into clear glass with the gradient rim. */
  .x-tile {
    --x-tile-fill: rgba(138, 61, 255, .10);
    --x-tile-dot: rgba(138, 61, 255, .14);
    position: relative;
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 18px 22px 18px 18px;
    border: 1.5px solid transparent;
    border-radius: 22px;
    background-color: var(--x-tile-fill);
    -webkit-background-clip: padding-box;
    background-clip: padding-box;
    color: var(--x-ink);
    text-decoration: none;
    transition: background .2s ease, box-shadow .2s ease;
  }

  .x-tile.x-tile--sky { --x-tile-fill: rgba(0, 194, 255, .10); --x-tile-dot: rgba(0, 194, 255, .16); }
  .x-tile.x-tile--magenta { --x-tile-fill: rgba(229, 70, 255, .10); --x-tile-dot: rgba(229, 70, 255, .15); }

  .x-tile-icon {
    display: grid;
    flex: none;
    place-items: center;
    width: 56px;
    height: 56px;
    border-radius: 999px;
    background: var(--x-tile-dot);
    color: var(--x-violet);
  }

  .x-tile--sky .x-tile-icon { color: #1677d9; }
  .x-tile--magenta .x-tile-icon { color: #b02ad6; }
  .x-tile-icon svg { width: 26px; height: 26px; }

  a.x-tile:hover,
  .x-tile.is-active,
  .x-tile[aria-current="true"],
  a.x-chip-sm:hover,
  .x-chip-sm.is-active,
  .x-chip-sm:has(input:checked),
  .x-glass-rim {
    background:
      linear-gradient(rgba(255, 255, 255, .86), rgba(246, 246, 255, .86)) padding-box,
      linear-gradient(130deg, rgba(0, 194, 255, .9), rgba(138, 61, 255, .55) 50%, rgba(229, 70, 255, .9)) border-box;
    -webkit-background-clip: padding-box, border-box;
    background-clip: padding-box, border-box;
    background-origin: padding-box, border-box;
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
    box-shadow: 0 0 0 3px rgba(255, 255, 255, .7), 0 10px 30px rgba(0, 194, 255, .16), 0 6px 22px rgba(138, 61, 255, .14);
  }

  a.x-chip-sm:hover,
  .x-chip-sm.is-active,
  .x-chip-sm:has(input:checked) {
    border: 1px solid transparent;
    color: var(--x-violet);
  }

  /* A glass orb holding an icon, as the bubbles around the X in the XONE deck:
     a frosted center and an iridescent sky-violet-magenta rim. Size it with --x-orb. */
  .x-orb {
    display: grid;
    flex: none;
    place-items: center;
    width: var(--x-orb, 88px);
    height: var(--x-orb, 88px);
    border: 2px solid transparent;
    border-radius: 999px;
    background:
      radial-gradient(circle at 34% 28%, rgba(255, 255, 255, .98), rgba(255, 255, 255, .7) 42%, rgba(238, 234, 255, .62) 72%, rgba(220, 232, 255, .55)) padding-box,
      conic-gradient(from 210deg, rgba(0, 194, 255, .8), rgba(138, 61, 255, .7), rgba(229, 70, 255, .8), rgba(0, 194, 255, .8)) border-box;
    -webkit-background-clip: padding-box, border-box;
    background-clip: padding-box, border-box;
    background-origin: padding-box, border-box;
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    box-shadow: inset 0 0 18px rgba(138, 61, 255, .16), inset 0 -8px 16px rgba(0, 194, 255, .1), 0 14px 32px rgba(110, 80, 220, .18);
  }

  .x-orb svg { width: 44%; height: 44%; }

  /* The round gradient icon of the module cards ("X NETWORK", "X LEARN"…). */
  .x-chip-icon.x-chip-icon--solid {
    border-radius: 999px;
    background: var(--x-gradient);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .45), 0 6px 16px rgba(138, 61, 255, .3);
    color: #fff;
  }

  /* The glass X sphere from the deck sits on a white JPEG; multiply drops the white on light surfaces. */
  .x-sphere {
    mix-blend-mode: multiply;
    -webkit-mask-image: radial-gradient(circle at 50% 50%, #000 62%, transparent 71%);
    mask-image: radial-gradient(circle at 50% 50%, #000 62%, transparent 71%);
    animation: x-float 7s ease-in-out infinite;
  }

  /* A header link as a small glass bubble, like the X sphere: a frosted, slightly milky center,
     an iridescent sky-violet-magenta rim, and a white highlight on top. Hover brightens the rim. */
  .x-nav-glass {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 7px 14px;
    border: 1.5px solid transparent;
    border-radius: 999px;
    background:
      radial-gradient(120% 140% at 30% 0%, rgba(255, 255, 255, .95), rgba(255, 255, 255, .6) 45%, rgba(240, 236, 255, .55)) padding-box,
      linear-gradient(rgba(250, 250, 255, .9), rgba(250, 250, 255, .9)) padding-box,
      conic-gradient(from 200deg, rgba(0, 194, 255, .75), rgba(138, 61, 255, .55), rgba(229, 70, 255, .75), rgba(255, 255, 255, .9), rgba(0, 194, 255, .75)) border-box;
    -webkit-background-clip: padding-box, padding-box, border-box;
    background-clip: padding-box, padding-box, border-box;
    background-origin: padding-box, padding-box, border-box;
    -webkit-backdrop-filter: blur(12px) saturate(1.4);
    backdrop-filter: blur(12px) saturate(1.4);
    box-shadow: inset 0 1px 0 #fff, inset 0 -6px 12px rgba(138, 61, 255, .08), 0 4px 14px rgba(110, 80, 220, .12);
    color: var(--x-ink);
    font-weight: 600;
    line-height: 1.2;
    white-space: nowrap;
    text-decoration: none;
    transition: box-shadow .2s ease, transform .15s ease;
  }

  .x-nav-glass:hover {
    transform: translateY(-1px);
    box-shadow: inset 0 1px 0 #fff, inset 0 -6px 14px rgba(138, 61, 255, .12), 0 0 0 3px rgba(138, 61, 255, .1), 0 8px 20px rgba(0, 194, 255, .2);
  }

  .x-nav-glass[aria-current="page"] {
    background: var(--x-gradient);
    color: #fff;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .55), 0 8px 20px rgba(138, 61, 255, .28);
  }

  .x-on-dark .x-nav-glass,
  .x-nav-glass.x-on-dark {
    background:
      radial-gradient(120% 140% at 30% 0%, rgba(255, 255, 255, .22), rgba(255, 255, 255, .06) 50%, rgba(138, 61, 255, .1)) padding-box,
      linear-gradient(rgba(16, 18, 34, .78), rgba(16, 18, 34, .78)) padding-box,
      conic-gradient(from 200deg, rgba(0, 194, 255, .8), rgba(138, 61, 255, .6), rgba(229, 70, 255, .8), rgba(255, 255, 255, .6), rgba(0, 194, 255, .8)) border-box;
    -webkit-background-clip: padding-box, padding-box, border-box;
    background-clip: padding-box, padding-box, border-box;
    background-origin: padding-box, padding-box, border-box;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .35), 0 4px 14px rgba(0, 0, 0, .25);
    color: #fff;
  }

  /* CORA floats bottom-right as the whole robot: a slow bob and a violet-sky glow under it. */
  .cora-mascot {
    filter: drop-shadow(0 18px 22px rgba(138, 61, 255, .32)) drop-shadow(0 4px 10px rgba(0, 194, 255, .18));
    animation: x-float 4.2s ease-in-out infinite;
  }

  /* Now and then CORA gives a small wiggle, so a visitor notices it without being interrupted:
     still for about twelve seconds, then a short tilt and hop. It rests while the chat is open. */
  .cora-nudge {
    transform-origin: 50% 100%;
    animation: cora-nudge 14s ease-in-out 4s infinite;
  }

  .cora-mascot[aria-expanded="true"] .cora-nudge { animation: none; }

  .cora-mascot:hover { filter: drop-shadow(0 18px 26px rgba(138, 61, 255, .48)) drop-shadow(0 4px 12px rgba(0, 194, 255, .3)); }
  .cora-mascot:focus-visible { filter: drop-shadow(0 0 0 var(--x-violet)) drop-shadow(0 0 6px rgba(138, 61, 255, .9)); }

  /* The speech bubble above CORA, with a tail that points down at it. */
  .cora-bubble { animation: x-pop .18s ease-out; transform-origin: 85% 100%; }

  /* CORA's speech bubble, in the style of Kuida's: white, a thick border (here the XONE gradient),
     round corners, and a point aimed down at CORA. */
  .cora-speech {
    border: 2.5px solid transparent;
    border-radius: 28px 28px 10px 28px;
    background: linear-gradient(#fff, #fff) padding-box, var(--x-gradient) border-box;
    -webkit-background-clip: padding-box, border-box;
    background-clip: padding-box, border-box;
    background-origin: padding-box, border-box;
    box-shadow: 0 18px 44px rgba(92, 64, 190, .22), 0 4px 12px rgba(11, 15, 26, .06);
  }

  .cora-bubble::after {
    content: "";
    position: absolute;
    right: 38px;
    bottom: -11px;
    width: 20px;
    height: 20px;
    border-right: 2.5px solid var(--x-magenta);
    border-bottom: 2.5px solid var(--x-magenta);
    border-bottom-right-radius: 5px;
    background: #fff;
    transform: rotate(45deg);
    clip-path: polygon(100% 0, 100% 100%, 0 100%);
  }

  /* A chip that wraps a hidden checkbox still shows where the keyboard is. */
  .x-chip-sm:has(input:focus-visible) { outline: 2px solid var(--x-violet); outline-offset: 2px; }

  @media (prefers-reduced-motion: reduce) {
    .x-btn,
    .x-btn-glass,
    .x-chip,
    .x-chip-sm,
    .x-tile,
    .x-nav-glass { transition: none; }
    .cora-mascot,
    .cora-nudge,
    .cora-bubble,
    .x-sphere { animation: none; }
  }
}

@keyframes x-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

@keyframes x-pop {
  from { opacity: 0; transform: translateY(8px) scale(.97); }
  to { opacity: 1; transform: none; }
}

@keyframes cora-nudge {
  0%, 84%, 100% { transform: none; }
  87% { transform: translateY(-7px) rotate(-5deg); }
  90% { transform: translateY(-2px) rotate(4deg); }
  93% { transform: translateY(-4px) rotate(-2.5deg); }
  96% { transform: rotate(1deg); }
}

/* Apple adjustments. html.is-apple is set from shared/_xone_head before first paint.
   These rules are unlayered so they beat Tailwind's `appearance: button` and the
   Tailwind CDN on Vacantes and Talento. Linux and Windows never get the class. */

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

/* A date's intrinsic min-width overflows the card on Safari. Other browsers already fit. */
input[type="date"],
input[type="datetime-local"],
input[type="time"],
input[type="month"],
input[type="week"] {
  min-width: 0;
  max-width: 100%;
}

html.is-apple {
  -webkit-font-smoothing: subpixel-antialiased;
  -moz-osx-font-smoothing: auto;
}

/* Safari paints only the first line of a gradient phrase unless each line repeats the fill.
   100vw on the phone bubble includes the scrollbar and pushes the page sideways. */
html.is-apple .x-gradient-text {
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}

html.is-apple .cora-speech {
  max-width: calc(100% - 24px);
}

@media (max-width: 639px) {
  html.is-apple .cora-speech {
    left: 12px;
    right: 12px;
    width: auto;
  }
}

html.is-apple [data-cora-target="log"] {
  max-height: min(440px, calc(100dvh - 320px));
}

/* A float on the same element as the mask makes Safari drop the mask and show the square JPEG. */
html.is-apple .x-sphere {
  animation: none;
}

html.is-apple img[class~="w-full"] {
  min-width: 0;
}

html.is-apple button,
html.is-apple input:is([type="button"], [type="submit"], [type="reset"]),
html.is-apple .x-btn,
html.is-apple .x-btn-glass,
html.is-apple .x-nav-glass,
html.is-apple .xtop-out {
  -webkit-appearance: none;
  appearance: none;
}

html.is-apple input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="file"]):not([type="date"]):not([type="time"]):not([type="datetime-local"]):not([type="month"]):not([type="week"]),
html.is-apple textarea,
html.is-apple input[type="search"] {
  -webkit-appearance: none;
  appearance: none;
}

html.is-apple input[type="search"]::-webkit-search-decoration,
html.is-apple input[type="search"]::-webkit-search-cancel-button,
html.is-apple input[type="search"]::-webkit-search-results-button,
html.is-apple input[type="search"]::-webkit-search-results-decoration {
  -webkit-appearance: none;
  display: none;
}

input[type="number"] {
  min-width: 0;
  max-width: 100%;
}

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

/* The real file input stays available to the label, and the visible control is the button beside it. */
.x-photo-input {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

html.is-apple input[type="file"] {
  min-width: 0;
  max-width: 100%;
}

html.is-apple input[type="file"]::file-selector-button {
  -webkit-appearance: none;
  appearance: none;
  margin-inline-end: 0.75rem;
  border: 0;
  border-radius: 999px;
  background: var(--x-paper);
  padding: 0.45rem 0.8rem;
  font: inherit;
  font-weight: 600;
  color: var(--x-ink);
}

html.is-apple .grid > *,
html.is-apple .flex > .flex-1 {
  min-width: 0;
}

html.is-apple .overflow-x-auto {
  scrollbar-gutter: stable;
}

/* Safari does not blur what scrolls under a sticky bar. The frost sits on a layer behind the links. */
html.is-apple .xtop {
  background: transparent;
  isolation: isolate;
}

html.is-apple .xtop::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: rgba(255, 255, 255, .78);
  -webkit-backdrop-filter: blur(16px) saturate(1.4);
  backdrop-filter: blur(16px) saturate(1.4);
  pointer-events: none;
}

html.is-apple select {
  -webkit-appearance: none;
  appearance: none;
  min-width: 0;
  max-width: 100%;
  padding-right: 1.75rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236b7088' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 14px;
}

/* Safari's range keeps the native track unless -webkit-appearance is none, then the thumb
   sits on a 3px box and has to be pulled back to center. */
html.is-apple .range {
  -webkit-appearance: none;
  appearance: none;
  height: 12px;
  background: transparent;
}

html.is-apple .range::-webkit-slider-runnable-track {
  height: 3px;
  background: rgba(255, 255, 255, .42);
  border: 0;
  border-radius: 99px;
}

html.is-apple .range::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  margin-top: -4.5px;
}

/* Focusing a field under 16px zooms the page on iPhone and iPad. Desktop Mac is not is-ios. */
html.is-ios input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="button"]):not([type="submit"]):not([type="reset"]):not([type="hidden"]):not([type="file"]),
html.is-ios select,
html.is-ios textarea {
  font-size: 16px;
}

/* XLEARN, shared by the landing deck and the course catalog. */
.x-learn { background: #fff; padding: 80px 0; }
.x-learn-grid {
  width: min(1400px, 100%);
  margin: 0 auto;
  padding: 0 24px;
  display: grid;
  align-items: center;
  gap: 48px;
}
.x-learn-kicker {
  margin: 0;
  font-family: var(--x-font-display);
  font-size: 18px;
  font-weight: 800;
  letter-spacing: .3em;
}
.x-learn h2 {
  margin: 20px 0 0;
  font-family: var(--x-font-display);
  font-size: 36px;
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -1.5px;
}
.x-learn-lead { margin: 24px 0 0; max-width: 620px; font-size: 18px; line-height: 32px; color: rgba(11, 15, 26, .85); }
.x-learn-sub { margin: 12px 0 0; font-size: 18px; font-weight: 500; color: var(--x-violet); }
.x-learn-go { margin-top: 32px; }
.x-learn-go .x-btn { padding: 14px 28px; font-size: 16px; }
.x-learn-go .x-btn svg { width: 20px; height: 20px; flex: none; }
.x-learn-tiles { margin-top: 40px; display: grid; gap: 12px; }
.x-learn-tiles .font-bold { font-weight: 700; }
.x-learn-note { margin: 32px 0 0; max-width: 520px; font-size: 16px; line-height: 28px; color: var(--x-muted); }
.x-learn-photo { width: 100%; height: 420px; object-fit: cover; border-radius: 28px; }
@media (min-width: 640px) {
  .x-learn-tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (min-width: 1024px) {
  .x-learn { padding: 96px 0; }
  .x-learn-grid { grid-template-columns: 1.2fr 1fr; padding: 0 40px; }
  .x-learn h2 { font-size: 56px; }
  .x-learn-photo { height: 640px; }
}

/* XCREDENTIALS, under XLEARN on the course catalog. */
.x-cred {
  padding: 80px 0;
  background-color: var(--x-cream);
  background-image:
    radial-gradient(ellipse 50% 60% at 85% 20%, rgba(138, 61, 255, .09), transparent 70%),
    radial-gradient(ellipse 45% 55% at 10% 90%, rgba(0, 194, 255, .08), transparent 70%);
}
.x-cred-grid { width: min(1400px, 100%); margin: 0 auto; padding: 0 24px; display: grid; align-items: center; gap: 48px; }
.x-cred-kicker { margin: 0; font-family: var(--x-font-display); font-size: 24px; font-weight: 800; letter-spacing: -.5px; }
.x-cred-tag { margin: 4px 0 0; font-size: 12px; font-weight: 500; letter-spacing: .5em; text-transform: uppercase; color: var(--x-muted); }
.x-cred h2 { margin: 32px 0 0; font-family: var(--x-font-display); font-size: 36px; font-weight: 700; line-height: 1.05; letter-spacing: -1.5px; }
.x-cred-lead { margin: 24px 0 0; max-width: 560px; font-size: 18px; line-height: 32px; color: rgba(11, 15, 26, .85); }
.x-cred-go { margin-top: 32px; }
.x-cred-go .x-btn { padding: 14px 28px; font-size: 16px; }
.x-cred-go .x-btn svg { width: 20px; height: 20px; flex: none; }
.x-cred-note { margin: 40px 0 0; display: flex; align-items: center; gap: 16px; font-size: 14px; letter-spacing: .25em; color: var(--x-muted); }
.x-cred-art { position: relative; width: 100%; max-width: 560px; aspect-ratio: 1; margin: 0 auto; }
.x-cred-sphere { position: absolute; inset: 6%; width: 88%; height: 88%; }
.x-cred-card { position: absolute; left: 50%; top: 50%; width: 62%; display: flex; align-items: center; gap: 16px; padding: 22px; border-radius: 24px; transform: translate(-50%, -50%) rotate(-6deg); }
.x-cred-lines { flex: 1; display: grid; gap: 8px; }
.x-cred-lines span { height: 10px; border-radius: 999px; background: rgba(138, 61, 255, .25); }
.x-cred-lines span:nth-child(2) { width: 80%; background: rgba(0, 194, 255, .25); }
.x-cred-lines span:nth-child(3) { width: 60%; background: rgba(138, 61, 255, .2); }
.x-cred-chip { position: absolute; }
@media (min-width: 1024px) {
  .x-cred { padding: 96px 0; }
  .x-cred-grid { grid-template-columns: 1fr 1fr; padding: 0 40px; }
  .x-cred h2 { font-size: 56px; }
}
