/* 3Bird split home: styles for the blocks on the Home and Swarmjar pages.
   Each tile carries the colours of where it leads: Sixth Sense in the robotics
   page's ink and lime, Swarmjar in its own ultraviolet, the AI Day in 3Bird
   blue and gold, ICT consulting in 3Bird blue and sky.

   Editors only touch text: icons and arrows come from here, chosen by the
   tile's class (tbsh-tile-robotics, -swarmjar, -aiday, -ict). */

.tbsh-intro,
.tbsh-tiles,
.tbsh-section,
.tbsh-help,
.tbsh-faq,
.tbsh-external {
  --tbsh-accent: #fbbf24;
  --tbsh-ink: #0a1628;
  --tbsh-ink-2: #12233a;
  --tbsh-line: rgba(255, 255, 255, .1);
  --tbsh-text: rgba(255, 255, 255, .78);
  --tbsh-fa: "Font Awesome 6 Free";
}

/* Themes without theme.json (like 3bird2-theme) get an extra
   .wp-block-group__inner-container inside every Group block. Inside these
   sections it takes no part in the layout, so grids and flex rows apply to
   the blocks themselves, with or without it. */
:is(.tbsh-intro, .tbsh-tiles, .tbsh-section, .tbsh-help, .tbsh-faq, .tbsh-external) .wp-block-group__inner-container {
  display: contents;
}

.tbsh-wrap {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ── Intro ── */
.tbsh-intro {
  padding: 8.5rem 0 2.75rem;
  color: #fff;
  background:
    radial-gradient(600px 300px at 12% 0%, rgba(169, 224, 79, .10), transparent 70%),
    radial-gradient(700px 320px at 88% 10%, rgba(79, 70, 255, .16), transparent 70%),
    var(--tbsh-ink);
}
.tbsh-intro .tbsh-eyebrow,
.tbsh-faq .tbsh-eyebrow {
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, .6);
  margin: 0 0 .9rem;
}
.tbsh-intro h1 {
  color: #fff;
  font-size: clamp(2rem, 4.4vw, 3.2rem);
  letter-spacing: -.02em;
  max-width: 22ch;
  margin: 0 0 1rem;
}
.tbsh-intro .tbsh-lead {
  color: var(--tbsh-text);
  font-size: 1.12rem;
  line-height: 1.6;
  max-width: 640px;
  margin: 0;
}

/* ── Tiles ── */
.tbsh-tiles {
  background: var(--tbsh-ink);
  padding: 0 0 3.5rem;
}
.tbsh-tiles .tbsh-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
}

/* Defaults on a single class, so the per-tile colour rules further down win. */
.tbsh-tile {
  --tile-accent: #fff;
  --tile-bg: var(--tbsh-ink-2);
}
.tbsh-grid .tbsh-tile {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 470px;
  margin: 0;
  padding: 1.75rem 1.6rem 1.5rem;
  border-radius: 20px;
  border: 1px solid var(--tbsh-line);
  background: var(--tile-bg);
  color: #fff;
  overflow: hidden;
  transition: transform .25s ease, border-color .25s ease, box-shadow .25s ease;
}
.tbsh-tile::before { /* accent bar */
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 4px;
  background: var(--tile-accent);
}
.tbsh-grid .tbsh-tile:hover,
.tbsh-grid .tbsh-tile:focus-within {
  transform: translateY(-4px);
  border-color: var(--tile-accent);
  box-shadow: 0 24px 48px -20px rgba(0, 0, 0, .6);
}

/* Icon, drawn above the label. */
.tbsh-tile .tbsh-kicker::before {
  content: var(--tile-icon);
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  margin-bottom: 1.4rem;
  border-radius: 14px;
  background-color: rgba(255, 255, 255, .07);
  color: var(--tile-accent);
  font-family: var(--tbsh-fa);
  font-weight: 900;
  font-size: 1.35rem;
  letter-spacing: 0;
  text-transform: none;
}
.tbsh-tile .tbsh-kicker {
  color: var(--tile-accent);
  font-size: .76rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  margin: 0 0 .4rem;
}
.tbsh-tile .tbsh-name {
  font-size: clamp(1.35rem, 1.9vw, 1.65rem);
  letter-spacing: -.01em;
  margin: 0 0 .8rem;
}
.tbsh-tile .tbsh-name a {
  color: #fff;
  text-decoration: none;
}
.tbsh-tile .tbsh-name a::after { /* the whole tile is the link */
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  z-index: 1;
}
.tbsh-tile .tbsh-name a:focus-visible { outline: none; }
.tbsh-grid .tbsh-tile:has(a:focus-visible) {
  outline: 3px solid var(--tile-accent);
  outline-offset: 3px;
}
.tbsh-tile .tbsh-text {
  color: var(--tbsh-text);
  font-size: .97rem;
  line-height: 1.6;
  margin: 0;
}
.tbsh-tile .tbsh-points {
  list-style: none;
  margin: 1.25rem 0 0;
  padding: 1.1rem 0 0;
  border-top: 1px solid var(--tbsh-line);
  display: grid;
  gap: .55rem;
}
.tbsh-points li {
  position: relative;
  margin: 0;
  padding-left: 1.3rem;
  font-size: .92rem;
  line-height: 1.45;
  color: rgba(255, 255, 255, .9);
}
.tbsh-points li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .45em;
  width: .5rem;
  height: .5rem;
  border-radius: 2px;
  background: var(--tile-accent);
}
.tbsh-tile .tbsh-cta {
  margin: auto 0 0;
  padding-top: 1.6rem;
  font-size: .98rem;
  font-weight: 700;
  color: var(--tile-accent);
}
.tbsh-tile .tbsh-cta::after {
  content: "\f061"; /* arrow-right */
  display: inline-block;
  margin-left: .5rem;
  font-family: var(--tbsh-fa);
  font-weight: 900;
  font-size: .9em;
  transition: transform .2s ease;
}
.tbsh-tile .tbsh-cta-external::after { content: "\f35d"; } /* arrow-up-right-from-square */
.tbsh-tile:hover .tbsh-cta::after { transform: translateX(4px); }

/* Line up label, name, text, list and link across the tiles in a row, so
   the lists start at one height however long each description is. */
@supports (grid-template-rows: subgrid) {
  .tbsh-grid .tbsh-tile {
    display: grid;
    grid-row: span 5;
    grid-template-rows: subgrid;
    row-gap: 0;
    align-items: start;
  }
  .tbsh-tile .tbsh-cta { align-self: end; }
}

.tbsh-tile-robotics {
  --tile-accent: #a9e04f;
  --tile-icon: "\f544"; /* robot */
  --tile-bg: linear-gradient(165deg, #1b3050 0%, #12233a 45%, #0d1b2e 100%);
}
.tbsh-tile-swarmjar {
  --tile-accent: #8c84ff;
  --tile-icon: "";
  --tile-bg: linear-gradient(165deg, #1d2552 0%, #151c42 45%, #0f1533 100%);
}
.tbsh-tile-swarmjar .tbsh-kicker::before { /* Swarmjar's own mark */
  background: rgba(255, 255, 255, .07) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Cpath d='M31 18H16v64h15M69 18h15v64H69' fill='none' stroke='%238C84FF' stroke-width='12' stroke-linecap='square'/%3E%3Crect x='42.5' y='24' width='15' height='15' fill='%23EEF1F8'/%3E%3Crect x='61' y='42.5' width='15' height='15' fill='%23EEF1F8'/%3E%3Crect x='24' y='61' width='15' height='15' fill='%23EEF1F8'/%3E%3Crect x='42.5' y='61' width='15' height='15' fill='%23EEF1F8'/%3E%3Crect x='61' y='61' width='15' height='15' fill='%23EEF1F8'/%3E%3C/svg%3E") center / 28px no-repeat;
}
.tbsh-tile-aiday {
  --tile-accent: #fbbf24;
  --tile-icon: "\f274"; /* calendar-check */
  --tile-bg: linear-gradient(165deg, #1d3f8f 0%, #13285e 45%, #0f2147 100%);
}
.tbsh-tile-ict {
  --tile-accent: #38bdf8;
  --tile-icon: "\f5fc"; /* laptop-code */
  --tile-bg: linear-gradient(165deg, #0c4a6e 0%, #0f3557 45%, #0f2147 100%);
}

/* ── Not sure? ── */
.tbsh-help {
  background: var(--tbsh-ink-2);
  border-top: 1px solid var(--tbsh-line);
  padding: 3rem 0;
  color: #fff;
}
.tbsh-help .tbsh-help-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}
.tbsh-help-inner :is(.tbsh-help-copy, .tbsh-help-actions) { margin: 0; }
.tbsh-help-copy h2 {
  color: #fff;
  font-size: clamp(1.4rem, 2.4vw, 1.9rem);
  margin: 0 0 .5rem;
}
.tbsh-help-copy p {
  color: var(--tbsh-text);
  font-size: 1rem;
  line-height: 1.6;
  max-width: 600px;
  margin: 0;
}
.tbsh-help .tbsh-help-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: .75rem;
  flex-shrink: 0;
}
.tbsh-help-actions :is(.wp-block-buttons, .tbsh-call) { margin: 0; }
.tbsh-btn .wp-block-button__link {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: 1rem 2.2rem;
  border-radius: 50px;
  background: linear-gradient(135deg, #f59e0b, #fbbf24);
  color: #0a1628;
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
  box-shadow: 0 4px 15px rgba(245, 158, 11, .35);
  transition: transform .2s ease, box-shadow .2s ease;
}
.tbsh-btn .wp-block-button__link::before {
  content: "\f274"; /* calendar-check */
  font-family: var(--tbsh-fa);
  font-weight: 900;
}
.tbsh-btn .wp-block-button__link:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(245, 158, 11, .45);
}
.tbsh-help .tbsh-call {
  color: var(--tbsh-text);
  font-size: .95rem;
}
.tbsh-call a { color: #fff; font-weight: 700; white-space: nowrap; text-decoration: none; }
.tbsh-call a:hover { color: #fbbf24; }

/* ── FAQ ── */
.tbsh-faq {
  background: #f8fafc;
  color: #1e293b;
  padding: 5rem 0;
}
.tbsh-faq .tbsh-wrap { max-width: 820px; }
.tbsh-faq .tbsh-eyebrow { color: #3b82f6; text-align: center; }
.tbsh-faq h2 {
  color: #0a1628;
  font-size: clamp(1.6rem, 3.5vw, 2.5rem);
  text-align: center;
  margin: 0 0 2.5rem;
}
.tbsh-faq .wp-block-details {
  margin: 0 0 .75rem;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
  padding: 0 1.4rem;
}
.tbsh-faq .wp-block-details summary {
  cursor: pointer;
  list-style: none;
  padding: 1.15rem 2rem 1.15rem 0;
  position: relative;
  font-weight: 700;
  font-size: 1.05rem;
}
.tbsh-faq .wp-block-details summary::-webkit-details-marker { display: none; }
.tbsh-faq .wp-block-details summary::after {
  content: "+";
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.4rem;
  font-weight: 400;
  color: #3b82f6;
}
.tbsh-faq .wp-block-details[open] summary::after { content: "−"; }
.tbsh-faq .wp-block-details p {
  margin: 0 0 1.2rem;
  color: #475569;
  line-height: 1.65;
}

/* ── Brand pages (Swarmjar): accent, hero buttons, sections, cards ── */
.tbsh-uv { --tbsh-accent: #8c84ff; }
.tbsh-intro.tbsh-uv .tbsh-eyebrow,
.tbsh-section .tbsh-eyebrow { color: var(--tbsh-accent); }

.tbsh-intro .tbsh-actions {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
  margin: 2rem 0 0;
}
.tbsh-btn-ghost .wp-block-button__link {
  display: inline-flex;
  align-items: center;
  padding: 1rem 2.2rem;
  border-radius: 50px;
  border: 1px solid rgba(255, 255, 255, .35);
  background: transparent;
  color: #fff;
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
}
.tbsh-btn-ghost .wp-block-button__link:hover { border-color: var(--tbsh-accent); color: var(--tbsh-accent); }

.tbsh-section {
  background: var(--tbsh-ink);
  color: #fff;
  padding: 4.5rem 0;
}
.tbsh-section-alt { background: var(--tbsh-ink-2); }
.tbsh-section .tbsh-eyebrow {
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  margin: 0 0 .8rem;
}
.tbsh-section h2 {
  color: #fff;
  font-size: clamp(1.6rem, 3.2vw, 2.4rem);
  letter-spacing: -.01em;
  max-width: 24ch;
  margin: 0 0 1rem;
}
.tbsh-section .tbsh-section-lead {
  color: var(--tbsh-text);
  font-size: 1.08rem;
  line-height: 1.6;
  max-width: 680px;
  margin: 0;
}
.tbsh-section .tbsh-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin: 2.25rem 0 0;
}
.tbsh-cards .tbsh-card {
  margin: 0;
  padding: 1.5rem 1.4rem;
  border-radius: 16px;
  border: 1px solid var(--tbsh-line);
  border-top: 3px solid var(--tbsh-accent);
  background: rgba(255, 255, 255, .04);
}
.tbsh-card h3 {
  color: #fff;
  font-size: 1.15rem;
  margin: 0 0 .5rem;
}
.tbsh-card p {
  color: var(--tbsh-text);
  font-size: .95rem;
  line-height: 1.6;
  margin: 0;
}
.tbsh-card .tbsh-num {
  color: var(--tbsh-accent);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: .85rem;
  font-weight: 700;
  margin: 0 0 .6rem;
}

/* The way off the site: last on the page, quiet, clearly external. */
.tbsh-external {
  background: var(--tbsh-ink);
  border-top: 1px solid var(--tbsh-line);
  padding: 2.25rem 0;
  color: var(--tbsh-text);
}
.tbsh-external .tbsh-external-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: .75rem 2rem;
}
.tbsh-external-inner p { margin: 0; font-size: .98rem; }
.tbsh-external .tbsh-external-link a {
  color: var(--tbsh-accent);
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}
.tbsh-external .tbsh-external-link a::after {
  content: "\f35d"; /* arrow-up-right-from-square */
  margin-left: .5rem;
  font-family: var(--tbsh-fa);
  font-weight: 900;
  font-size: .85em;
}
.tbsh-external .tbsh-external-link a:hover { text-decoration: underline; }

/* ── Smaller screens ── */
@media (max-width: 1100px) {
  .tbsh-tiles .tbsh-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tbsh-grid .tbsh-tile { min-height: 0; }
}
@media (max-width: 760px) {
  .tbsh-help .tbsh-help-inner { flex-direction: column; align-items: flex-start; }
  .tbsh-help .tbsh-help-actions { align-items: stretch; width: 100%; }
  .tbsh-btn, .tbsh-btn .wp-block-button__link { width: 100%; justify-content: center; }
}
@media (max-width: 640px) {
  .tbsh-intro { padding: 7rem 0 2rem; }
  .tbsh-tiles .tbsh-grid { grid-template-columns: 1fr; }
  .tbsh-grid .tbsh-tile { padding: 1.5rem 1.3rem 1.3rem; }
  .tbsh-tile .tbsh-kicker::before { margin-bottom: 1rem; }
  .tbsh-faq { padding: 3.5rem 0; }
  .tbsh-section { padding: 3.25rem 0; }
  .tbsh-intro .tbsh-actions .wp-block-button,
  .tbsh-intro .tbsh-actions .wp-block-button__link { width: 100%; justify-content: center; }
}
@media (prefers-reduced-motion: reduce) {
  .tbsh-grid .tbsh-tile, .tbsh-tile .tbsh-cta::after { transition: none; }
  .tbsh-grid .tbsh-tile:hover, .tbsh-grid .tbsh-tile:focus-within { transform: none; }
}
