/* BRAND CHROME — Fingal Alerts ('sidebar' chrome, templates/chrome/sidebar/).
   Recreates the old alerts.fingal.ie (Joomla + YOOtheme Pro) header, sidebar, footer and
   type, measured from the live site (Nov 2026). Loaded after site.css; colours from theme.css.
   Note: the original Fingal colours for the pink outline buttons (#D272CA), the section tab
   text (orange/green/blue) and the footer links are kept exactly as they were, although they
   are below the WCAG 2.1 AA 4.5:1 text contrast. Darker values are listed at the end. */

:root {
  --sb-text: #2C362E;
  --sb-pink: var(--fingal-tab-purple); /* outline buttons, login button (dark purple: WCAG AA; was var(--accent-3)) */
  --sb-pink-text: var(--fingal-tab-purple);
  --sb-footer-bg: var(--primary-1);
  --sb-footer-link: var(--fingal-tab-purple);  /* #5A0E56, WCAG AA on the footer background (was var(--primary-4) #A05599) */
  --sb-rule: #CDCCC6;
  --sb-container: 1400px;
}

/* ---- Type (YOOtheme: Open Sans 16px / 1.74, light headings) ---- */
html { font-size: 16px; line-height: 1.74; color: var(--sb-text); }
body { color: var(--sb-text); }
.ma-chrome-sidebar h1, .ma-chrome-sidebar .uk-h1 { font-size: 36px; font-weight: 300; line-height: 1.4; color: var(--sb-text); letter-spacing: 0; margin: 0 0 20px; }
.ma-chrome-sidebar h2, .ma-chrome-sidebar .uk-h2 { font-size: 24px; font-weight: 400; line-height: 1.35; color: var(--sb-text); letter-spacing: 0; }
.ma-chrome-sidebar h3, .ma-chrome-sidebar .uk-h3 { font-size: 19px; font-weight: 600; line-height: 1.4; color: var(--sb-text); letter-spacing: 0; }
.ma-chrome-sidebar h4 { font-size: 17px; font-weight: 600; color: var(--sb-text); }
.ma-chrome-sidebar p, .ma-chrome-sidebar li { max-width: none; }
.ma-chrome-sidebar a { color: var(--primary-5); text-decoration: none; }
.ma-chrome-sidebar a:hover { color: var(--primary-5); text-decoration: underline; }
.ma-chrome-sidebar main p a:not(.uk-button):not(.ma-btn-double), .ma-chrome-sidebar main li a:not(.uk-button), .ma-chrome-sidebar main td a { text-decoration: underline; }
.ma-chrome-sidebar main .uk-button { text-decoration: none !important; }
.ma-chrome-sidebar .ma-label { color: var(--sb-text); font-size: 14px; }

/* ---- Layout ---- */
.ma-sb-container { box-sizing: content-box; max-width: var(--sb-container); margin: 0 auto; padding: 0 15px; }
@media (min-width: 640px) { .ma-sb-container { padding: 0 20px; } }
@media (min-width: 960px) {
  .ma-sb-container { padding: 0 40px; }
  /* The old site sat on a white page with a 20px margin either side */
  .ma-chrome-sidebar { padding: 0 20px; }
}

/* ---- Desktop toolbar ---- */
.ma-sb-toolbar { background: #fff; padding: 10px 0; font-size: 13px; }
.ma-sb-utility { list-style: none; margin: 0; padding: 0; display: flex; justify-content: flex-end; align-items: center; gap: 20px; }
.ma-sb-utility li { line-height: 1.74; }
.ma-sb-utility form { margin: 0; }
.ma-sb-utility a:not(.ma-sb-login) { font-size: 12px; font-weight: 600; text-transform: uppercase; color: var(--sb-text) !important; text-decoration: none; }
.ma-sb-utility a:not(.ma-sb-login):hover { text-decoration: underline; }
.ma-sb-login { position: relative; display: inline-flex; align-items: center; gap: 6px; padding: 0 20px; border: 1px solid var(--sb-pink); border-radius: 4px; background: #fff;
  font: 600 12px/23px var(--font); text-transform: uppercase; color: var(--sb-text) !important; text-decoration: none !important; cursor: pointer; }
.ma-sb-login::before { content: ""; position: absolute; top: 2px; bottom: 2px; left: -4px; right: -4px; border: 1px solid var(--sb-pink); border-radius: 4px; pointer-events: none; }
.ma-sb-login [uk-icon] { color: var(--sb-pink); }
.ma-sb-login:hover { background: var(--primary-1); }
.ma-lang a { margin-left: 6px; }

/* ---- Desktop navbar: logo + coloured sections ---- */
.ma-sb-navbar { position: relative; z-index: 2; background: #fff; box-shadow: 0 11px 8px -10px #6F6F6F; }
.ma-sb-navbar .ma-sb-container { display: flex; align-items: center; gap: 15px; min-height: 70px; }
.ma-sb-navbar .ma-sb-logo { position: relative; top: -14px; line-height: 0; margin-right: auto; }
.ma-sb-logo img { display: block; width: 178px; height: auto; }
.ma-sb-sections ul { list-style: none; margin: 0; padding: 0; display: flex; align-items: stretch; gap: 40px; }
.ma-sb-sections a { display: flex; align-items: center; justify-content: center; box-sizing: border-box; min-height: 70px; padding: 0 30px; margin-right: 1px;
  font-size: 22px; font-weight: 400; text-decoration: none !important; border-bottom: 8px solid; transition: background-color .1s, color .1s; }
.ma-sb-sections a.ma-sb-orange { color: var(--fingal-orange); border-color: var(--fingal-orange); }
.ma-sb-sections a.ma-sb-green  { color: var(--fingal-green);  border-color: var(--fingal-green); }
.ma-sb-sections a.ma-sb-blue   { color: var(--fingal-blue);   border-color: var(--fingal-blue); }
.ma-sb-sections a.ma-sb-purple { color: var(--fingal-purple); border-color: var(--fingal-purple); }
.ma-sb-sections a.ma-sb-orange:hover, .ma-sb-sections a.ma-sb-orange.is-active { background: var(--fingal-orange); color: #fff; }
.ma-sb-sections a.ma-sb-green:hover,  .ma-sb-sections a.ma-sb-green.is-active  { background: var(--fingal-green);  color: #fff; }
.ma-sb-sections a.ma-sb-blue:hover,   .ma-sb-sections a.ma-sb-blue.is-active   { background: var(--fingal-blue);   color: #fff; }
.ma-sb-sections a.ma-sb-purple:hover, .ma-sb-sections a.ma-sb-purple.is-active { background: var(--fingal-purple); color: #fff; }
@media (min-width: 960px) and (max-width: 1199px) {
  .ma-sb-sections ul { gap: 12px; }
  .ma-sb-sections a { padding: 0 18px; font-size: 20px; }
}
.ma-sb-search { display: flex; align-items: center; min-height: 70px; padding: 0 0 0 10px; color: var(--sb-text) !important; }

/* 'filled' section tabs (header.section_style), as on fingal.ie since Nov 2026: solid blocks
   with white upper-case text, 1px apart, sitting on the bottom of the header; the search icon
   after them has a grey rule underneath. */
.ma-sb-sections-filled { align-self: flex-end; }
.ma-sb-sections-filled ul { gap: 1px; }
.ma-sb-sections-filled a { min-height: 54px; padding: 8px 48px; margin-right: 0; font-size: 20px; font-weight: 300; line-height: 30px; text-transform: uppercase;
  color: #fff !important; border-bottom: 8px solid; }
.ma-sb-sections-filled a.ma-sb-orange { background: var(--fingal-tab-orange); border-color: var(--fingal-tab-orange); }
.ma-sb-sections-filled a.ma-sb-green  { background: var(--fingal-tab-green);  border-color: var(--fingal-tab-green); }
.ma-sb-sections-filled a.ma-sb-blue   { background: var(--fingal-tab-blue);   border-color: var(--fingal-tab-blue); }
.ma-sb-sections-filled a.ma-sb-purple { background: var(--fingal-tab-purple); border-color: var(--fingal-tab-purple); }
.ma-sb-sections-filled a.ma-sb-orange:hover, .ma-sb-sections-filled a.ma-sb-orange:focus-visible, .ma-sb-sections-filled a.ma-sb-orange.is-active { background: var(--fingal-tab-orange-on); border-color: var(--fingal-tab-orange-on); }
.ma-sb-sections-filled a.ma-sb-green:hover,  .ma-sb-sections-filled a.ma-sb-green:focus-visible,  .ma-sb-sections-filled a.ma-sb-green.is-active  { background: var(--fingal-tab-green-on);  border-color: var(--fingal-tab-green-on); }
.ma-sb-sections-filled a.ma-sb-blue:hover,   .ma-sb-sections-filled a.ma-sb-blue:focus-visible,   .ma-sb-sections-filled a.ma-sb-blue.is-active   { background: var(--fingal-tab-blue-on);   border-color: var(--fingal-tab-blue-on); }
.ma-sb-sections-filled a.ma-sb-purple:hover, .ma-sb-sections-filled a.ma-sb-purple:focus-visible, .ma-sb-sections-filled a.ma-sb-purple.is-active { background: var(--fingal-tab-purple-on); border-color: var(--fingal-tab-purple-on); }
.ma-sb-sections-filled + .ma-sb-search { align-self: flex-end; min-height: 0; height: 46px; padding: 0 0 0 2px; margin-left: 4px; box-sizing: border-box;
  align-items: flex-start; border-bottom: 8px solid var(--fingal-search-rule); color: var(--fingal-tab-purple) !important; }
.ma-sb-sections-filled + .ma-sb-search [uk-icon] svg { width: 30px; height: 30px; }
@media (min-width: 960px) and (max-width: 1199px) {
  .ma-sb-sections-filled a { padding: 8px 24px; font-size: 18px; }
}

/* ---- Breadcrumb bar ---- */
.ma-sb-top { background: #fff; padding-top: 6px; }
.ma-sb-breadcrumb { list-style: none; margin: 0 0 40px; padding: 5px 5px 5px 15px; display: flex; flex-wrap: wrap; font-size: 13px; font-weight: 300; }
.ma-sb-breadcrumb li + li::before { content: ">"; margin: 0 4px; color: #303945; }
.ma-sb-breadcrumb a { color: #303945; }
.ma-sb-breadcrumb [aria-current] { color: var(--sb-text); }

/* ---- Phones: menu button, centred logo, Account ---- */
.ma-sb-mobilebar { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; min-height: 80px; padding: 0 15px; background: #fff; }
.ma-sb-toggle { justify-self: start; background: none; border: 0; padding: 10px; margin-left: -10px; color: var(--sb-text); cursor: pointer; min-width: 44px; min-height: 44px; }
.ma-sb-mobilebar .ma-sb-logo img { width: 150px; }
.ma-sb-account { justify-self: end; font-size: 14px; text-decoration: underline !important; }

.ma-sb-offcanvas .uk-offcanvas-bar { background: #fff; color: var(--sb-text); width: 300px; padding: 56px 20px 24px; }
.ma-sb-offcanvas .uk-offcanvas-close { color: var(--sb-text); }
.ma-sb-offcanvas .ma-sb-menu { box-shadow: none; }
.ma-sb-offcanvas-links { list-style: none; margin: 24px 0 0; padding: 0; }
.ma-sb-offcanvas-links a { display: block; padding: 6px 0; font-size: 12px; font-weight: 600; text-transform: uppercase; color: var(--sb-text) !important; }

/* ---- Main area: content + sidebar (sidebar on the left from 960px, after the page on phones) ---- */
.ma-sb-main { background: #fff; padding-bottom: 60px; }
.ma-sb-grid { display: flex; flex-direction: column; gap: 40px; }
@media (min-width: 960px) { .ma-sb-grid { gap: 70px; } }
.ma-sb-content { flex: 1 1 auto; min-width: 0; outline: none; }
.ma-sb-sidebar { flex: 0 0 auto; }
@media (max-width: 959px) { .ma-sb-main { padding-top: 20px; } }
@media (min-width: 960px) {
  .ma-sb-grid { flex-direction: row; }
  .ma-sb-sidebar { order: -1; flex: 0 0 calc((100% + 70px) / 3 - 70px); min-width: 240px; }
}
/* Pages are written for a full-width layout; inside the content column they lose their own
   container padding and the big section spacing. */
.ma-sb-content .uk-container { max-width: none; padding-left: 0; padding-right: 0; }
.ma-sb-content .ma-section { padding-top: 0; padding-bottom: 0; }
.ma-sb-content > .ma-section:first-child > h1:first-child,
.ma-sb-content > .uk-container:first-child h1:first-of-type { margin-top: 0; }
.ma-sb-content .ma-breadcrumb { margin: 0 0 8px; font-size: 14px; }

/* Sidebar title (home page), menu and buttons */
.ma-sb-title { font-size: 45px; font-weight: 300; line-height: 1.2; margin: 0 0 20px; color: var(--sb-text); }
.ma-sb-menu { list-style: none; margin: 0; padding: 0; box-shadow: 5px -3px 7px #F1F1F1; }
.ma-sb-menu li { margin: 0; max-width: none; }
.ma-sb-menu a { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 20px; border-bottom: 1px solid var(--sb-rule);
  font-size: 18px; font-weight: 400; line-height: 1.74; color: var(--sb-text) !important; text-decoration: none !important; }
.ma-sb-menu a:hover, .ma-sb-menu a:focus-visible, .ma-sb-menu .is-active a { background: var(--primary-5); color: #fff !important; }
.ma-sb-menu .is-active a::after { content: ""; flex: 0 0 18px; height: 14px; margin-right: auto; margin-left: 4px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 18 14'%3E%3Cpath d='M1 7h15M10.5 1.5 16 7l-5.5 5.5' fill='none' stroke='%23fff' stroke-width='1.6'/%3E%3C/svg%3E") no-repeat center / contain; }
.ma-sb-menu .is-active a { justify-content: flex-start; }
.ma-sb-buttons { display: flex; flex-direction: column; gap: 22px; margin: 30px 0 0; padding: 0 7px; }
.ma-sb-buttons form { margin: 0; }
.ma-sb-buttons .ma-btn-double { width: 100%; }

/* The double pink outline button ("btn btn-primary" on the old site) */
.ma-btn-double { position: relative; display: inline-block; box-sizing: border-box; padding: 15px 20px; border: 1px solid var(--sb-pink); border-radius: 4px; background: transparent;
  font: 600 14px/38px var(--font); text-transform: uppercase; text-align: center; color: var(--sb-pink-text) !important; text-decoration: none !important; cursor: pointer; }
.ma-btn-double::before { content: ""; position: absolute; top: 5px; bottom: 5px; left: -7px; right: -7px; border: 1px solid var(--sb-pink); border-radius: 4px; pointer-events: none; }
.ma-btn-double:hover, .ma-btn-double:focus-visible { background: var(--primary-1); }
.ma-btn-double-wide { width: 300px; max-width: calc(100% - 14px); }

/* Home page */
.ma-sb-home { max-width: none; }
.ma-sb-home > p { text-align: justify; }
/* Home page tagline: a real h2 (it reads as the heading of the intro), styled as before */
.ma-sb-home .ma-sb-lead { font-family: var(--font); font-size: 20px; font-weight: 600; line-height: 1.4; letter-spacing: normal; text-transform: none; color: var(--sb-text); text-align: left; margin: 40px 0 20px; }
.ma-sb-home ul { padding-left: 30px; }
.ma-sb-home-actions { display: flex; flex-direction: column; align-items: center; gap: 30px; margin: 30px 0 20px; }

/* ---- Buttons and forms inside pages (Joomla forms: solid purple buttons, grey inputs) ---- */
.ma-chrome-sidebar .uk-button { border-radius: 3px; font-size: 14px; font-weight: 600; padding: 9px 18px; line-height: 1.5; }
.ma-chrome-sidebar .uk-button-large { font-size: 15px; padding: 11px 24px; }
.ma-chrome-sidebar .uk-button-primary { background: var(--primary-5); border-color: var(--primary-5); color: #fff; }
.ma-chrome-sidebar .uk-button-primary:hover, .ma-chrome-sidebar .uk-button-primary:focus { background: #310C2F; border-color: #310C2F; color: #fff; }
.ma-chrome-sidebar .uk-button-default { color: var(--primary-5); border-color: var(--primary-5); }
.ma-chrome-sidebar .uk-input, .ma-chrome-sidebar .uk-select, .ma-chrome-sidebar .uk-textarea { height: 44px; border: 1px solid #C9CACE; border-radius: 3px; background: #F7F7F7; font-size: 16px; color: var(--sb-text); }
.ma-chrome-sidebar .uk-textarea { height: auto; }
.ma-chrome-sidebar .uk-input:focus, .ma-chrome-sidebar .uk-select:focus { background: #fff; border-color: var(--primary-5); }
.ma-chrome-sidebar .ma-field-error .uk-input { border: 2px solid var(--danger-6); }

/* ---- Footer ---- */
.ma-sb-footer { background: var(--sb-footer-bg); color: rgba(90, 22, 87, .7); padding-top: 30px; }
.ma-sb-footer-cols { display: grid; grid-template-columns: 1fr; gap: 30px 40px; padding-bottom: 30px; }
@media (min-width: 960px) { .ma-sb-footer-cols { grid-template-columns: repeat(3, 1fr); } }
.ma-sb-footer h2 { font-size: 20px; font-weight: 600; line-height: 1.4; color: var(--sb-text); margin: 0 0 20px; }
.ma-sb-footer ul { list-style: none; margin: 0; padding: 0; }
.ma-sb-footer-cols ul a { display: block; padding: 8px 0; font-size: 12px; font-weight: 600; line-height: 1.74; text-transform: uppercase; color: var(--sb-footer-link) !important; }
.ma-sb-social-heading { margin: 0 0 20px; }
.ma-sb-social-heading a { font-size: 16px; font-weight: 600; text-transform: uppercase; color: var(--sb-footer-link) !important; }
.ma-sb-social { display: flex; gap: 14px; padding-left: 4px !important; }
.ma-sb-social a { position: relative; display: flex; align-items: center; justify-content: center; width: 45px; height: 52px; border: 1px solid #CCC; border-radius: 4px; color: var(--primary-5) !important; }
.ma-sb-social a::before { content: ""; position: absolute; top: 2px; bottom: 2px; left: -4px; right: -4px; border: 1px solid #CCC; border-radius: 4px; pointer-events: none; }
.ma-sb-social a:hover { background: #fff; }
.ma-sb-footer-cols .ma-sb-social a { display: flex; padding: 0; }
.ma-sb-social a > span { display: flex; }
.ma-sb-footer hr { margin: 0; border: 0; border-top: 1px solid rgba(44, 54, 46, .1); }
.ma-sb-footer-bottom { padding-top: 20px; padding-bottom: 20px; }
.ma-sb-footer-bottom p { margin: 0 0 20px; font-size: 14px; line-height: 1.74; color: #000; }
.ma-sb-footer-bottom a, .ma-sb-footer-bottom .ma-link-button { color: var(--primary-5) !important; text-decoration: underline; font-size: 14px; }
@media (min-width: 960px) { .ma-sb-footer { margin-bottom: 20px; } }

/* Focus stays clearly visible on every chrome element */
.ma-chrome-sidebar :focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }

/* Higher-contrast alternatives (WCAG 2.1 AA, 4.5:1), if Fingal ever wants them:
   --sb-pink-text: #A8459E;  --fingal-orange: #C25B0E;  --fingal-green: #4A8A22;
   --fingal-blue: #007FB1;   --sb-footer-link: #8A3F83; */

/* More email alerts directory (/categories): cards like the old site's category grid */
.ma-xcat-grid { list-style: none; margin: 30px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 50px 30px; }
@media (max-width: 959px) { .ma-xcat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 639px) { .ma-xcat-grid { grid-template-columns: 1fr; } }
.ma-xcat-body { display: flex; flex-direction: column; flex: 1; }
.ma-xcat-wide { grid-column: 1 / -1; }
@media (min-width: 640px) {
  .ma-xcat-card.ma-xcat-wide { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); column-gap: 30px; align-items: start; }
  .ma-xcat-wide h2 { grid-column: 1 / -1; }
  .ma-xcat-wide .ma-xcat-body p:first-child { margin-top: 0; }
  .ma-xcat-wide .ma-xcat-body .ma-btn-double { align-self: flex-start; }
}
.ma-xcat-card { display: flex; flex-direction: column; max-width: none; }
.ma-xcat-card h2 { font-size: 30px; font-weight: 300; color: var(--primary-4); margin: 0 0 14px; }
.ma-xcat-card > img, .ma-xcat-noimg { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; border-radius: 6px; display: block; }
.ma-xcat-noimg { display: flex; align-items: center; justify-content: center; background: var(--primary-1); }
.ma-xcat-card p { margin: 16px 0 0; }
.ma-xcat-card .ma-xcat-count { margin-top: 6px; font-size: 14px; color: var(--text-muted); }
.ma-xcat-card .ma-btn-double { align-self: center; margin-top: 18px; padding: 10px 28px; }
.ma-xcat-hero { width: 100%; max-height: 320px; object-fit: cover; border-radius: 6px; margin: 0 0 20px; }

/* Live Map notice button ("Zoom in" / "Zoom out"): Fingal purple with white text (WCAG AA) */
.ma-livemap-notice .uk-button { background: var(--fingal-tab-purple); color: #fff; border: 1px solid #fff; }
.ma-livemap-notice .uk-button:hover, .ma-livemap-notice .uk-button:focus-visible { background: var(--primary-6); color: #fff; }
