/* Al Raheem blocks. Uses the theme's colour tokens with safe fallbacks. */
:root {
	--ar-gold: var(--wp--preset--color--gold, #C8A45D);
	--ar-gold-l: var(--wp--preset--color--gold-light, #E7CD93);
	--ar-bg: var(--wp--preset--color--ink, #0A0908);
	--ar-panel: var(--wp--preset--color--graphite, #1C1916);
	--ar-text: var(--wp--preset--color--ivory, #F3ECDF);
	--ar-soft: var(--wp--preset--color--champagne, #D9CAB0);
	--ar-muted: var(--wp--preset--color--muted, #A69A87);
	--ar-line: var(--wp--preset--color--line, #2E2822);
	--ar-up: #7FD9A3;
	--ar-down: #F2A0A6;
}

.ar-note, .ar-updated { font-size: .85rem; color: var(--ar-muted); }
.ar-dot { display: inline-block; width: .5em; height: .5em; border-radius: 50%; background: #3BD17A; margin-right: .45em; vertical-align: .1em; box-shadow: 0 0 0 0 rgba(59,209,122,.6); animation: ar-pulse 2.4s infinite; }
@keyframes ar-pulse { 70% { box-shadow: 0 0 0 7px rgba(59,209,122,0); } 100% { box-shadow: 0 0 0 0 rgba(59,209,122,0); } }
@media (prefers-reduced-motion: reduce) { .ar-dot { animation: none; } }

/* Ticker */
.ar-ticker { margin: 0; font-size: .8rem; }
.ar-ticker a { text-decoration: none; color: inherit !important; }
.ar-ticker strong { color: var(--ar-gold-l); font-weight: 600; }
.ar-ticker .ar-sep { opacity: .5; margin: 0 .3em; }
.ar-ticker .ar-chg { font-size: .75rem; }
@media (max-width: 600px) { .ar-ticker__more { display: none; } }

/* Change badge */
.ar-chg { font-weight: 600; white-space: nowrap; }
.ar-chg--up { color: var(--ar-up); }
.ar-chg--down { color: var(--ar-down); }
.ar-chg--flat { color: var(--ar-muted); }

/* Rate cards */
.ar-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr)); gap: 1rem; }
.ar-card { border: 1px solid rgba(200,164,93,.28); border-radius: 2px; padding: 1.35rem 1.4rem; background: linear-gradient(160deg, rgba(200,164,93,.08), rgba(10,9,8,.35)); backdrop-filter: blur(6px); transition: border-color .3s; }
.ar-card:hover { border-color: rgba(231,205,147,.6); }
.ar-card p { margin: 0; }
.ar-card__k { font-size: .66rem; letter-spacing: .3em; text-transform: uppercase; color: var(--ar-gold-l); font-weight: 600; }
.ar-card__v { font-family: var(--wp--preset--font-family--display, Georgia, serif); font-weight: 500; color: var(--ar-text); font-size: clamp(1.8rem, 3vw, 2.5rem); line-height: 1.15; margin-top: .35rem !important; font-variant-numeric: tabular-nums; }
.ar-card__n { font-size: .78rem; color: var(--ar-muted); }
.ar-card .ar-chg { display: inline-block; margin-top: .5rem; font-size: .8rem; }
.ar-updated a, .ar-note a { color: var(--ar-gold-l); }

/* Rate table */
.ar-rates table { font-variant-numeric: tabular-nums; background: var(--ar-panel); border: 1px solid var(--ar-line); border-radius: 2px; overflow: hidden; }
.ar-rates caption { caption-side: top; text-align: left; font-size: .7rem; letter-spacing: .22em; text-transform: uppercase; font-weight: 500; padding: 0 0 .9rem; color: var(--ar-gold); }
.ar-rates th[scope="row"] { font-weight: 500; white-space: nowrap; color: var(--ar-text); }
.ar-rates th small { display: block; font-weight: 400; color: var(--ar-muted); font-size: .75rem; }
.ar-rates td { font-weight: 400; color: var(--ar-soft); }
.ar-rates tbody tr:first-child td { color: var(--ar-gold-l); font-weight: 600; }
.ar-rates tbody tr:hover { background: rgba(200,164,93,.05); }
@media (max-width: 560px) {
	.ar-rates td, .ar-rates th { padding: .7rem .45rem !important; font-size: .85rem; white-space: nowrap; }
	.ar-rates thead th { font-size: .58rem; letter-spacing: .12em; }
	.ar-rates th:nth-child(4), .ar-rates td:nth-child(4) { display: none; }
	.ar-rates caption { letter-spacing: .12em; }
}

.ar-summary { font-size: 1.15rem; color: var(--ar-soft); }
.ar-summary strong { color: var(--ar-gold-l); }

/* Chart */
.ar-chart { margin: 1.5rem 0; }
.ar-chart figcaption { margin-bottom: .5rem; color: var(--ar-soft); }
.ar-chart__plot { position: relative; }
.ar-chart svg { width: 100%; height: auto; display: block; overflow: visible; touch-action: pan-y; }
.ar-chart .ar-grid { stroke: var(--ar-line); stroke-width: 1; }
.ar-chart .ar-line { fill: none; stroke: var(--ar-gold); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.ar-chart .ar-end, .ar-chart .ar-hover { fill: var(--ar-gold); stroke: var(--ar-bg); stroke-width: 2; }
.ar-chart .ar-endlabel { font-size: 13px; font-weight: 600; fill: var(--ar-text); }
.ar-chart .ar-axis { font-size: 12px; fill: var(--ar-muted); }
.ar-chart .ar-cross { stroke: var(--ar-muted); stroke-width: 1; stroke-dasharray: 3 3; }
.ar-tip { position: absolute; top: 0; transform: translate(-50%, -110%); background: var(--ar-text); color: var(--ar-bg); font-size: .8rem; padding: .35rem .6rem; border-radius: 8px; pointer-events: none; white-space: nowrap; }
.ar-table summary { cursor: pointer; font-size: .85rem; color: var(--ar-muted); margin-top: .5rem; }
.ar-table table { width: 100%; font-size: .85rem; font-variant-numeric: tabular-nums; margin-top: .5rem; }

/* Calculators */
.ar-calc { background: var(--ar-panel); border: 1px solid var(--ar-line); border-radius: 2px; padding: clamp(1.1rem, 3vw, 2rem); }
.ar-calc__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr)); gap: 1rem; }
.ar-calc label { display: flex; flex-direction: column; gap: .45rem; font-size: .66rem; font-weight: 500; letter-spacing: .2em; text-transform: uppercase; color: var(--ar-gold); }
.ar-calc input, .ar-calc select { font: inherit; font-size: 1rem; letter-spacing: 0; text-transform: none; color: var(--ar-text); padding: .7rem .8rem; border: 1px solid var(--ar-line); border-radius: 0; background: var(--ar-bg); color-scheme: dark; width: 100%; box-sizing: border-box; min-height: 48px; }
.ar-calc input:focus, .ar-calc select:focus { outline: 2px solid var(--ar-gold); outline-offset: 1px; }
.ar-calc__wide { grid-column: 1 / -1; }
.ar-calc__pair { display: flex; gap: .5rem; max-width: 34rem; }
.ar-calc__pair input { flex: 1 1 40%; } .ar-calc__pair select { flex: 1 1 60%; }
.ar-calc__out { display: block; margin-top: 1.25rem; padding: 1.4rem; border-left: 1px solid var(--ar-gold); background: linear-gradient(90deg, rgba(200,164,93,.1), rgba(200,164,93,0)); }
.ar-calc__out:empty { display: none; }
.ar-calc__total { font-family: var(--wp--preset--font-family--display, Georgia, serif); font-weight: 500; font-size: clamp(2rem, 4vw, 2.9rem); color: var(--ar-gold-l); line-height: 1.1; margin: 0; font-variant-numeric: tabular-nums; }
.ar-calc__lines { margin: .5rem 0 0; font-size: .9rem; color: var(--ar-muted); }

/* Enquire */
.ar-enquire { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.5rem; }
.ar-wa-btn { display: inline-flex !important; align-items: center; gap: .6rem; }
.ar-wa-btn svg { width: 1.15em; height: 1.15em; fill: currentColor; }

/* Map */
.ar-map iframe { width: 100%; aspect-ratio: 16 / 10; border: 1px solid var(--ar-line); border-radius: 2px; background: var(--ar-panel); filter: invert(.92) hue-rotate(180deg) saturate(.55) brightness(.95) contrast(.95); }
.ar-map p { margin-top: .6rem; font-size: .9rem; }

/* Floating WhatsApp */
.ar-wa-float { position: fixed; right: 18px; bottom: 18px; z-index: 99; width: 56px; height: 56px; border-radius: 50%; background: var(--ar-gold); display: grid; place-items: center; box-shadow: 0 0 0 1px rgba(231,205,147,.5), 0 12px 30px -8px rgba(0,0,0,.7); transition: transform .2s, background-color .2s; }
.ar-wa-float:hover { transform: scale(1.06); background: var(--ar-gold-l); }
.ar-wa-float svg { width: 27px; height: 27px; fill: var(--ar-bg); }
