/* Seven Blue Dots Core: block styles.
 * Colours and fonts come from the theme's presets when they exist
 * (ink, cobalt, sky, sun, orange, paper, white, muted, line; display, body),
 * so any theme can restyle them. Fallbacks match the Seven Blue Dots theme. */

.sbd-block {
	--sbd-ink: var(--wp--preset--color--ink, #0E1A3A);
	--sbd-blue: var(--wp--preset--color--cobalt, #1D3FD6);
	--sbd-sky: var(--wp--preset--color--sky, #4C6BFF);
	--sbd-sun: var(--wp--preset--color--sun, #FFC83D);
	--sbd-orange: var(--wp--preset--color--orange, #FF8A1F);
	--sbd-paper: var(--wp--preset--color--paper, #F4F1EA);
	--sbd-card: var(--wp--preset--color--white, #FFFFFF);
	--sbd-muted: var(--wp--preset--color--muted, #4B5675);
	--sbd-line: var(--wp--preset--color--line, #E2DDD2);
	--sbd-display: var(--wp--preset--font-family--display, inherit);
	--sbd-radius: 20px;
	box-sizing: border-box;
}
.sbd-block *, .sbd-block *::before, .sbd-block *::after { box-sizing: border-box; }
.sbd-block :where(h1, h2, h3, p, dl, dd, ul, ol) { margin: 0; }
.sbd-block :where(ul, ol) { padding: 0; list-style: none; }
.sbd-block .screen-reader-text, .sbd-hp {
	position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
	overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.sbd-kicker {
	font-weight: 700; font-size: 0.875rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--sbd-blue);
}
.sbd-note, .sbd-disclosure, .sbd-updated { font-size: 0.85rem; color: var(--sbd-muted); margin-top: 12px; }
.sbd-empty { padding: 24px; border: 2px dashed var(--sbd-line); border-radius: var(--sbd-radius); color: var(--sbd-muted); }

/* Dots */
.sbd-dots { display: inline-flex; align-items: center; gap: 6px; vertical-align: middle; }
.sbd-dot { width: 14px; height: 14px; border-radius: 50%; border: 2px solid #B9B2A2; display: inline-block; }
.sbd-dot.is-on { background: var(--sbd-blue); border-color: var(--sbd-blue); }
.sbd-dots--s .sbd-dot { width: 10px; height: 10px; }
.sbd-dots--l { gap: 8px; }
.sbd-dots--l .sbd-dot { width: 26px; height: 26px; }

/* Airport picker */
.sbd-picker__label { font-size: 0.95rem; margin-bottom: 12px; opacity: 0.85; }
.sbd-picker__list { display: flex; flex-wrap: wrap; gap: 10px; }
.sbd-chip {
	display: inline-flex; align-items: center; min-height: 44px; padding: 10px 20px; border-radius: 999px;
	font-weight: 700; text-decoration: none; color: inherit;
	border: 2px solid color-mix(in srgb, currentColor 35%, transparent);
	transition: background-color .15s, border-color .15s;
}
.sbd-chip:hover { border-color: currentColor; }
.sbd-chip.is-active { background: var(--sbd-sun); border-color: var(--sbd-sun); color: var(--sbd-ink); }
.sbd-chip:focus-visible { outline: 3px solid var(--sbd-sun); outline-offset: 2px; }

/* Weather + pick cards */
.sbd-weather, .sbd-pick {
	display: flex; align-items: center; gap: 20px; padding: 24px; border-radius: var(--sbd-radius);
	background: color-mix(in srgb, currentColor 9%, transparent);
}
.sbd-pick { background: var(--sbd-sun); color: var(--sbd-ink); }
.sbd-icon { width: 56px; height: 56px; flex: 0 0 56px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; opacity: .8; }
.sbd-weather__kicker { font-size: 0.875rem; opacity: 0.8; }
.sbd-weather__kicker a { color: inherit; }
.sbd-weather__temp { font-family: var(--sbd-display); font-weight: 700; font-size: clamp(1.75rem, 4vw, 2.5rem); line-height: 1.1; margin-top: 4px !important; }
.sbd-weather__temp a { color: inherit; text-decoration: none; }
.sbd-weather__line { margin-top: 4px !important; }

/* Card grid */
.sbd-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); gap: 24px; }
.sbd-card {
	display: flex; flex-direction: column; gap: 14px; padding: 24px; border-radius: var(--sbd-radius);
	background: var(--sbd-card); border: 1px solid var(--sbd-line); color: var(--sbd-ink); text-decoration: none;
	transition: transform .15s, box-shadow .15s;
}
.sbd-card:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(14, 26, 58, .08); }
.sbd-card:focus-visible { outline: 3px solid var(--sbd-blue); outline-offset: 3px; }
.sbd-card__top { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.sbd-card__title { font-family: var(--sbd-display); font-weight: 700; font-size: 1.75rem; line-height: 1.1; }
.sbd-card__meta { display: block; font-size: 0.95rem; color: var(--sbd-muted); margin-top: 2px; }
.sbd-card__temp { font-family: var(--sbd-display); font-weight: 700; font-size: 1.875rem; }
.sbd-card__dots { display: flex; align-items: center; gap: 8px; }
.sbd-card__score { font-weight: 700; font-size: 0.875rem; color: var(--sbd-blue); }
.sbd-card__verdict { font-size: 1.0625rem; line-height: 1.45; }

/* Verdict */
.sbd-verdict {
	display: flex; flex-wrap: wrap; gap: 48px; padding: clamp(24px, 5vw, 48px);
	background: var(--sbd-card); color: var(--sbd-ink); border: 1px solid var(--sbd-line); border-radius: 28px;
}
.sbd-verdict__main { flex: 1 1 340px; min-width: 0; display: flex; flex-direction: column; gap: 16px; }
.sbd-verdict__title { font-family: var(--sbd-display); font-weight: 800; font-size: clamp(2rem, 5vw, 2.75rem); line-height: 1.05; letter-spacing: -0.02em; }
.sbd-verdict__line { font-size: 1.2rem; line-height: 1.5; color: #33405F; }
.sbd-verdict__explain { font-size: 0.95rem; color: var(--sbd-muted); }
.sbd-scores { flex: 1 1 400px; min-width: 0; display: flex; flex-direction: column; gap: 18px; justify-content: center; }
.sbd-score dt { font-weight: 700; }
.sbd-score dd { margin: 4px 0 0; }
.sbd-score__text { display: block; color: #33405F; font-size: 0.95rem; }
.sbd-bar { display: block; height: 10px; margin-top: 8px; background: #ECE8DE; border-radius: 999px; overflow: hidden; }
.sbd-bar > span { display: block; height: 100%; background: var(--sbd-blue); border-radius: 999px; }

/* Postcards */
.sbd-postcard {
	display: block; padding: 26px; background: var(--sbd-card); color: var(--sbd-ink); text-decoration: none;
	border-radius: 6px; box-shadow: 0 2px 0 var(--sbd-line), 0 18px 36px rgba(14, 26, 58, .08);
	transition: transform .2s;
}
.sbd-postcard--0 { transform: rotate(-1.2deg); }
.sbd-postcard--1 { transform: rotate(0.8deg); }
.sbd-postcard--2 { transform: rotate(-0.6deg); }
.sbd-postcard:hover { transform: rotate(0deg) translateY(-3px); }
.sbd-postcard:focus-visible { outline: 3px solid var(--sbd-blue); outline-offset: 4px; }
.sbd-postcard__head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 22px; }
.sbd-stamp {
	width: 74px; height: 88px; border: 3px dotted var(--sbd-ink); display: flex; align-items: center; justify-content: center;
	font-family: var(--sbd-display); font-weight: 800; font-size: 1.4rem; color: #fff; background: var(--sbd-ink);
}
.sbd-stamp--1 { background: var(--sbd-blue); }
.sbd-stamp--2 { background: #C2410C; }
.sbd-postmark {
	width: 92px; height: 92px; border-radius: 50%; border: 2px solid var(--sbd-muted); display: flex; align-items: center; justify-content: center;
	text-align: center; font-size: 0.7rem; font-weight: 700; letter-spacing: 0.08em; color: var(--sbd-muted); transform: rotate(-12deg); padding: 8px;
}
.sbd-postcard .sbd-kicker { display: block; font-size: 0.8rem; }
.sbd-postcard__title { font-family: var(--sbd-display); font-weight: 700; font-size: 1.55rem; line-height: 1.2; margin-top: 8px !important; }
.sbd-postcard__blurb { display: block; margin-top: 10px; color: var(--sbd-muted); line-height: 1.5; }

/* Sun Alert */
.sbd-alert {
	position: relative; overflow: hidden; display: flex; flex-wrap: wrap; gap: 32px; align-items: center; justify-content: space-between;
	padding: clamp(28px, 5vw, 48px); border-radius: 28px; background: var(--sbd-sun); color: var(--sbd-ink);
	scroll-margin-top: 24px;
}
.sbd-anchor { position: absolute; top: -24px; }
.sbd-alert__sun { position: absolute; right: -60px; top: -80px; width: 260px; height: 260px; fill: #fff; stroke: #fff; stroke-width: 10; stroke-linecap: round; opacity: .4; pointer-events: none; }
.sbd-alert__text { position: relative; flex: 1 1 380px; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
.sbd-alert .sbd-kicker { color: var(--sbd-ink); }
.sbd-alert__title { font-family: var(--sbd-display); font-weight: 800; font-size: clamp(2rem, 5vw, 2.75rem); line-height: 1.05; letter-spacing: -0.02em; }
.sbd-alert__form { position: relative; flex: 1 1 420px; min-width: 0; display: flex; flex-direction: column; gap: 12px; }
.sbd-alert__row { display: flex; flex-wrap: wrap; gap: 10px; }
.sbd-alert__row input[type=email], .sbd-alert__row select {
	flex: 1 1 200px; min-width: 0; font: inherit; font-size: 1.05rem; min-height: 52px; padding: 12px 20px;
	border-radius: 999px; border: 2px solid var(--sbd-ink); background: #fff; color: var(--sbd-ink);
}
.sbd-alert__row select { flex: 0 1 150px; }
.sbd-alert__row button, .sbd-button {
	display: inline-flex; align-items: center; justify-content: center; min-height: 52px; padding: 12px 26px; border-radius: 999px; border: 0;
	font: inherit; font-weight: 700; font-size: 1.05rem; background: var(--sbd-ink); color: #fff; cursor: pointer; text-decoration: none;
}
.sbd-alert__row button:hover, .sbd-button:hover { background: var(--sbd-blue); color: #fff; }
.sbd-alert__row :focus-visible, .sbd-button:focus-visible { outline: 3px solid var(--sbd-ink); outline-offset: 2px; }
.sbd-alert__consent { display: flex; gap: 10px; align-items: flex-start; font-size: 0.95rem; }
.sbd-alert__consent input { width: 20px; height: 20px; margin-top: 2px; flex: 0 0 20px; }
.sbd-alert__consent a { color: inherit; }
.sbd-alert__msg { font-weight: 700; }

/* Route hero */
.sbd-route { display: flex; flex-direction: column; gap: 18px; }
.sbd-route__title { font-family: var(--sbd-display); font-weight: 800; font-size: clamp(2.5rem, 7vw, 4.5rem); line-height: 0.98; letter-spacing: -0.03em; }
.sbd-route__verdict { font-size: 1.3rem; line-height: 1.45; max-width: 46ch; }
.sbd-route__dots { display: flex; align-items: center; gap: 14px; font-weight: 700; font-size: 1.25rem; }
.sbd-route .sbd-button { background: var(--sbd-sun); color: var(--sbd-ink); }
.sbd-route .sbd-button:hover { background: #fff; color: var(--sbd-ink); }
.sbd-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 170px), 1fr)); gap: 12px; }
.sbd-facts > div { padding: 16px 18px; border-radius: 16px; background: color-mix(in srgb, currentColor 9%, transparent); }
.sbd-facts dt { font-size: 0.8rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; opacity: .75; }
.sbd-facts dd { margin: 4px 0 0; font-weight: 700; font-size: 1.1rem; }

/* Route list on destination pages */
.sbd-routes__title { font-family: var(--sbd-display); font-weight: 800; font-size: 1.75rem; margin-bottom: 16px !important; }
.sbd-routes { display: flex; flex-direction: column; gap: 10px; }
.sbd-routes__item { display: flex; flex-wrap: wrap; gap: 6px 16px; align-items: baseline; padding: 16px 20px; background: var(--sbd-card); border: 1px solid var(--sbd-line); border-radius: 16px; }
.sbd-routes__link { font-weight: 700; font-size: 1.1rem; }
.sbd-routes__meta { color: var(--sbd-muted); }
.sbd-routes__fare { margin-left: auto; font-weight: 700; }

/* Month pages */
.sbd-month { display: flex; flex-direction: column; gap: 24px; }
.sbd-month__title { font-family: var(--sbd-display); font-weight: 800; font-size: clamp(2.25rem, 6vw, 3.75rem); line-height: 1; letter-spacing: -0.03em; }
.sbd-month__intro { font-size: 1.15rem; color: var(--sbd-muted); }
.sbd-months ul { display: flex; flex-wrap: wrap; gap: 8px; }
.sbd-months a { display: inline-flex; min-width: 54px; min-height: 44px; align-items: center; justify-content: center; padding: 8px 12px; border-radius: 10px; border: 1px solid var(--sbd-line); background: var(--sbd-card); text-decoration: none; font-weight: 700; color: var(--sbd-ink); }
.sbd-months a[aria-current] { background: var(--sbd-ink); color: #fff; border-color: var(--sbd-ink); }

/* Guide: weather table, FAQ, related */
.sbd-guide { display: flex; flex-direction: column; gap: 40px; }
.sbd-guide__section h2 { font-family: var(--sbd-display); font-weight: 800; font-size: clamp(1.6rem, 4vw, 2.25rem); letter-spacing: -0.02em; margin-bottom: 18px !important; }
.sbd-table-wrap { overflow-x: auto; border: 1px solid var(--sbd-line); border-radius: 16px; background: var(--sbd-card); }
.sbd-climate { width: 100%; min-width: 480px; border-collapse: collapse; }
.sbd-climate th, .sbd-climate td { padding: 10px 16px; text-align: left; border-bottom: 1px solid var(--sbd-line); }
.sbd-climate thead th { font-size: 0.8rem; letter-spacing: .06em; text-transform: uppercase; color: var(--sbd-muted); }
.sbd-climate tbody tr:last-child > * { border-bottom: 0; }
.sbd-climate tr.is-current { background: color-mix(in srgb, var(--sbd-sun) 30%, transparent); font-weight: 700; }
.sbd-faq { display: flex; flex-direction: column; gap: 10px; }
.sbd-faq details { background: var(--sbd-card); border: 1px solid var(--sbd-line); border-radius: 16px; padding: 0 20px; }
.sbd-faq summary { cursor: pointer; padding: 18px 0; font-weight: 700; font-size: 1.05rem; list-style-position: outside; }
.sbd-faq details p { padding: 0 0 18px; line-height: 1.6; }
.sbd-related__cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 24px; }
.sbd-related h3 { font-size: 1rem; font-weight: 700; margin-bottom: 10px !important; }
.sbd-related li { padding: 6px 0; }
.sbd-related li span { color: var(--sbd-muted); font-size: 0.85rem; }

/* Breadcrumbs */
.sbd-crumbs ol { display: flex; flex-wrap: wrap; gap: 6px; font-size: 0.9rem; }
.sbd-crumbs li + li::before { content: "›"; margin-right: 6px; opacity: .6; }
.sbd-crumbs a { color: inherit; }
.sbd-crumbs [aria-current] { opacity: .75; }

/* Share */
.sbd-share { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; }
.sbd-share__label { font-weight: 700; }
.sbd-share ul { display: flex; flex-wrap: wrap; gap: 8px; }
.sbd-share__btn {
	display: inline-flex; align-items: center; min-height: 44px; padding: 8px 18px; border-radius: 999px; font: inherit; font-weight: 700;
	border: 2px solid currentColor; background: transparent; color: inherit; text-decoration: none; cursor: pointer;
}
.sbd-share__btn--whatsapp { background: #128C4A; border-color: #128C4A; color: #fff; }
.sbd-share__btn:hover { opacity: .85; }

@media (prefers-reduced-motion: reduce) {
	.sbd-card, .sbd-postcard, .sbd-chip { transition: none; }
	.sbd-postcard, .sbd-postcard:hover { transform: none; }
}
