/*
Theme Name: Southport Rd Open Day
Theme URI: https://surfpacific.com.au
Author: Surf Pacific
Description: Minimal event landing page theme for Pain-Free Dentistry Smile Creation Open Day (19 May 2026). Pairs with the Clinic Growth Blocks plugin.
Version: 1.0
Requires at least: 6.4
Tested up to: 6.7
Requires PHP: 8.0
*/

/* Brand design tokens (gold #DBAB6B, navy #1C2A35/#293C4D, Albert Sans / Anybody / IBM Plex Sans). */
@import url('./brand/pfd-variables.css');

/* ============================================================
   CGB DESIGN-TOKEN BRIDGE
   Map the Clinic Growth Blocks tokens onto the PFD brand vars.
   This is the only place the two systems meet — change palette
   here and every CGB block re-skins automatically.
   ============================================================ */
:root {
  --cgb-main:            var(--pfd-gold);
  --cgb-main-clr:        var(--pfd-gold);
  --cgb-utility:         var(--pfd-mid-navy);
  --cgb-main-gradient:   var(--pfd-deep-navy);
  --cgb-light-bg:        var(--pfd-warm-white);
  --cgb-radius:          var(--radius-md);
  --cgb-radius-lg:       var(--radius-lg);
  --cgb-radius-btn:      var(--radius-none);  /* PFD buttons are square */
  --cgb-heading-font:    var(--font-display);
  --cgb-body-font:       var(--font-body);

  /* Bridges for legacy variables some CGB blocks reference */
  --main-clr:            var(--pfd-gold);
  --logo-green:          var(--pfd-mid-navy);
  --main-gradient:       var(--pfd-deep-navy);
  --aileron-font:        var(--font-display);
  --bodyfont:            var(--font-body);
}

/* ============================================================
   GLOBAL RESET & TYPOGRAPHY (older-patient priority: ≥18px, line-height 1.7)
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.7;
  color: var(--pfd-text-dark);
  background: #fff;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--pfd-gold); text-decoration: none; }
a:hover { color: #c49250; }

/* Visible focus ring for keyboard users */
:focus-visible {
  outline: 3px solid var(--pfd-gold);
  outline-offset: 2px;
}

/* ============================================================
   SHARED CONTAINER (matches CGB .container expectation)
   ============================================================ */
.container {
  width: 100%;
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: 24px;
}

/* Bootstrap-like row/col fallbacks so CGB blocks render without Bootstrap. */
.row { display: flex; flex-wrap: wrap; margin-inline: -12px; }
.row > [class^="col-"], .row > [class*=" col-"] { padding-inline: 12px; }
.col-lg-4 { flex: 0 0 100%; max-width: 100%; }
.col-lg-5 { flex: 0 0 100%; max-width: 100%; }
.col-lg-6 { flex: 0 0 100%; max-width: 100%; }
.col-lg-7 { flex: 0 0 100%; max-width: 100%; }
.col-lg-8 { flex: 0 0 100%; max-width: 100%; }

@media (min-width: 992px) {
  .col-lg-4 { flex: 0 0 33.333%; max-width: 33.333%; }
  .col-lg-5 { flex: 0 0 41.666%; max-width: 41.666%; }
  .col-lg-6 { flex: 0 0 50%; max-width: 50%; }
  .col-lg-7 { flex: 0 0 58.333%; max-width: 58.333%; }
  .col-lg-8 { flex: 0 0 66.666%; max-width: 66.666%; }
}

.g-4 > * { margin-bottom: 24px; }
.align-items-stretch { align-items: stretch; }
.align-items-start   { align-items: flex-start; }
.align-items-center  { align-items: center; }

/* ============================================================
   STICKY HEADER
   ============================================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 999;
  background: var(--pfd-mid-navy);
  padding: 12px 0;
  box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}

.site-header__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding-inline: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.site-header__logo {
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}

.site-header__logo-img {
  display: block;
  height: 100px;
  width: auto;
  /* Logo PNG is dark navy on transparent — invert to white for the navy header. */
  filter: brightness(0) invert(1);
  transition: opacity 0.2s ease;
}

.site-header__logo:hover .site-header__logo-img { opacity: 0.9; }

.site-header__actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.site-header__phone {
  color: #fff;
  text-decoration: none;
  font-family: var(--font-body);
  font-size: 16px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  min-height: 44px;
  padding: 6px 8px;
}

.site-header__phone:hover { color: var(--pfd-gold); }

.site-header__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--pfd-gold);
  color: var(--pfd-near-black);
  font-family: var(--font-sub);
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  padding: 12px 22px;
  border-radius: var(--radius-none);
  min-height: 48px;          /* WCAG 2.5.5 */
  white-space: nowrap;
  transition: background-color 0.2s ease;
}

.site-header__cta:hover {
  background: #c49250;
  color: var(--pfd-near-black);
}

@media (max-width: 640px) {
  .site-header__phone { display: none; }
  .site-header__cta   { padding: 10px 16px; font-size: 14px; }
  .site-header__logo-img { height: 80px; }
}

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer {
  background: var(--pfd-mid-navy);
  color: rgba(255,255,255,0.85);
  padding: 64px 0 32px;
  margin-top: 0;
}

.site-footer__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding-inline: 24px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 40px;
}

.site-footer__col h3 {
  font-family: var(--font-sub);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--pfd-gold);
  margin: 0 0 14px;
}

.site-footer__col p,
.site-footer__col address,
.site-footer__col li {
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.6;
  color: rgba(255,255,255,0.78);
  font-style: normal;
  margin: 0 0 8px;
}

.site-footer__col ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.site-footer__col a {
  color: rgba(255,255,255,0.78);
  text-decoration: none;
}
.site-footer__col a:hover { color: var(--pfd-gold); }

.site-footer__logo {
  display: block;
  height: auto;
  width: 360px;
  max-width: 100%;
  margin-bottom: 16px;
  filter: brightness(0) invert(1);  /* white-out on navy footer */
}

.site-footer__legal {
  font-size: 12px;
  color: rgba(255,255,255,0.5);
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid rgba(255,255,255,0.1);
  grid-column: 1 / -1;
}

/* ============================================================
   GENERIC BUTTON CLASSES (used by CGB blocks)
   ============================================================ */
.btncn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-sub);
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  padding: 12px 28px;
  min-height: 48px;
  border-radius: var(--radius-none);
  border: 1px solid transparent;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
  white-space: nowrap;
}

.btncn-default {
  background: var(--pfd-gold);
  color: var(--pfd-near-black);
}
.btncn-default:hover { background: #c49250; color: var(--pfd-near-black); }

.btncn-white {
  background: transparent;
  color: var(--pfd-cream);
  border-color: var(--pfd-cream);
}
.btncn-white:hover { background: var(--pfd-gold); border-color: var(--pfd-gold); color: var(--pfd-near-black); }

/* ============================================================
   ACCESSIBILITY: Skip link
   ============================================================ */
.skip-link {
  position: absolute;
  top: -40px;
  left: 8px;
  background: var(--pfd-gold);
  color: var(--pfd-near-black);
  padding: 8px 16px;
  font-weight: 600;
  text-decoration: none;
  z-index: 1000;
  transition: top 0.2s ease;
}
.skip-link:focus { top: 8px; }

/* ============================================================
   GRAVITY FORMS — readable defaults
   ============================================================ */
.gform_wrapper input[type="text"],
.gform_wrapper input[type="email"],
.gform_wrapper input[type="tel"],
.gform_wrapper select,
.gform_wrapper textarea {
  font-family: var(--font-body);
  font-size: 16px;       /* prevents iOS zoom */
  line-height: 1.5;
  padding: 12px 14px;
  min-height: 48px;
  border: 1px solid rgba(28, 42, 53, 0.2);
  border-radius: var(--radius-sm);
  width: 100%;
}

.gform_wrapper label {
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 500;
  color: var(--pfd-text-dark);
  margin-bottom: 6px;
  display: block;
}

.gform_wrapper .gfield_required { color: #b22; margin-left: 4px; }

.gform_wrapper .gform_button {
  background: var(--pfd-gold);
  color: var(--pfd-near-black);
  font-family: var(--font-sub);
  font-size: 16px;
  font-weight: 600;
  border: none;
  padding: 14px 32px;
  min-height: 52px;
  border-radius: var(--radius-none);
  cursor: pointer;
  width: 100%;
  transition: background-color 0.2s ease;
}
.gform_wrapper .gform_button:hover { background: #c49250; }

.gform_confirmation_message {
  background: var(--pfd-warm-white);
  border-left: 4px solid var(--pfd-gold);
  padding: 24px;
  font-size: 17px;
  line-height: 1.6;
  border-radius: var(--radius-sm);
}
