/* =========================================================
   SHARED BASE — WORDPRESS/ASTRA COMPATIBILITY
   Astra theme integration and safe overrides
========================================================= */

/* =========================================================
   ASTRA COLOR BINDING
   Astra MUST consume GiftFlow tokens
========================================================= */

:root {
  /* Astra global palette */
  --ast-global-color-0: var(--gf-primary);        /* Primary */
  --ast-global-color-1: var(--gf-primary-soft);   /* Secondary */
  --ast-global-color-2: var(--gf-text-main);      /* Headings */
  --ast-global-color-3: var(--gf-text-muted);     /* Body text */
  --ast-global-color-4: #ffffff;                  /* White */
  --ast-global-color-5: var(--gf-bg-main);        /* Background */
  --ast-global-color-6: var(--gf-text-main);      /* Dark */
  --ast-global-color-7: var(--gf-primary-soft);   /* Subtle bg */
  --ast-global-color-8: #000000;                  /* Black (rare) */

  /* Astra borders */
  --ast-border-color: rgba(138, 92, 255, 0.18);
}

/* =========================================================
   ASTRA OVERRIDES
   Non-destructive color binding
========================================================= */

body,
.ast-container,
.ast-site-title,
.ast-site-header {
  color: var(--gf-text-main);
}

/* Links */
a,
.ast-menu-toggle,
.ast-header-button {
  color: var(--gf-primary);
}

a:hover,
.ast-menu-toggle:hover {
  color: #6F5CFF;
}

/* =========================================================
   ASTRA LAYOUT FIXES
========================================================= */

/* ASTRA FLEX FIX — NO SIDEBAR PAGES */
.ast-no-sidebar .site-content .ast-container {
  display: block;
}

/* Dashboard hard neutralisation moved to assets/css/layouts/dashboard.css
   See Phase 10 documentation for details.
========================================================= */

/* =========================================================
   ASTRA HARD NEUTRALISATION — DASHBOARD/APP PAGES
   Safe - used in style.css
========================================================= */

.gf-dashboard-page .ast-container,
.gf-dashboard-page .site-content,
.gf-dashboard-page .content-area,
.gf-dashboard-page .site-main {
  max-width: none !important;
  padding: 0 !important;
  margin: 0 !important;
}

/* Ensure GiftFlow shell owns spacing */
.gf-dashboard-page .gf-app-shell {
  width: 100%;
}

/* =========================================================
   ASTRA CONTAINER BYPASS — PUBLIC PAGES
   Public page width moved to assets/css/layouts/public.css
   Astra container bypass remains here for .ast-container
========================================================= */

/* Kill Astra clamp */
.gf-public-page .ast-container,
.gf-public-profile .ast-container {
  max-width: none !important;
  padding: 0 !important;
  margin: 0 !important;
}

/* =========================================================
   ASTRA HEADER CUSTOMIZATION
========================================================= */

.ast-container {
  background:
    radial-gradient(
      ellipse at 50% 220px,
      rgba(124, 77, 255, 0.05) 0%,
      rgba(124, 77, 255, 0.03) 38%,
      rgba(124, 77, 255, 0.015) 58%,
      transparent 80%
    );
}

/* Header logo position adjustment */
.gf-app-shell .ast-builder-grid-row > .site-header-section {
    flex-wrap: nowrap;
    margin-left: 5%;
}

/* Sidebar link active state */
.gf-sidebar-link {
  color: var(--gf-text-main);
}

.gf-sidebar-link.is-active {
  background: var(--gf-primary-soft);
  color: var(--gf-primary);
}
