/*
 Theme Name:   Sumo Academy Child
 Theme URI:    https://sumoacademy.exprestage.com
 Description:  Blank Divi child theme for the Sumo Academy staging rebuild.
 Author:       EXPRE Digital
 Template:     Divi
 Version:      1.0.0
 License:      GNU General Public License v2 or later
 License URI:  https://www.gnu.org/licenses/gpl-2.0.html
 Text Domain:  sumoacademy-child
*/

/* Brand colours extracted from live site (see migration/content/brand.json) */
:root {
    --sa-bg:         #0e0e0e;
    --sa-bg-alt:     #272727;
    --sa-text:       #f6f6f6;
    --sa-text-muted: #a9a9a9;
    --sa-accent:     #00b2ff;
    --sa-accent-alt: #f0523d;
}

body {
    background-color: var(--sa-bg);
    color: var(--sa-text);
    font-family: "Poppins", "Helvetica Neue", Helvetica, Arial, sans-serif;
}

h1, h2, h3, h4, h5, h6 {
    font-family: "Poppins", "Helvetica Neue", Helvetica, Arial, sans-serif;
    color: var(--sa-text);
}

a           { color: var(--sa-accent); }
a:hover     { color: #33c4ff; }

/* ==========================================================================
   Header — match live Squarespace layout
   ========================================================================== */

/* Remove white separator */
#main-header,
#top-header {
    background-color: var(--sa-bg) !important;
    box-shadow: none !important;
    border-bottom: none !important;
}
#main-header .nav li a,
#top-menu a {
    color: var(--sa-text) !important;
    text-transform: none !important;
    font-weight: 400 !important;
}
/* Current page indicator — a bottom underline that does NOT change the
   link's box height (which was pushing the current item down vs the rest). */
#top-menu li.current-menu-item > a,
#top-menu li.current_page_item > a {
    position: relative;
    border-bottom: 0 !important;
    padding-bottom: 0 !important;
}
#top-menu li.current-menu-item > a::after,
#top-menu li.current_page_item > a::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -4px;
    height: 1px;
    background: var(--sa-text);
}
/* Keep every nav link on the same baseline regardless of state */
#top-menu li,
#top-menu li > a {
    display: inline-flex !important;
    align-items: center !important;
    line-height: 1.2 !important;
    padding-top: 0 !important;
}

/* Hide Divi search magnifier */
#et_top_search,
#et-top-navigation #et_search_icon {
    display: none !important;
}

/* Transparent header overlaid on hero — applies to every front-end page,
   matching the live Squarespace layout. */
body:not(.et-tb-has-header) #main-header {
    background: transparent !important;
    position: absolute !important;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 99;
    box-shadow: none !important;
}
body.et_fixed_nav.et_show_nav #page-container {
    padding-top: 0 !important;
}
body #main-header.et-fixed-header {
    background: rgba(14, 14, 14, 0.9) !important;  /* solid-ish once scrolled */
}

/* Nav text readability: subtle shadow + a dark gradient behind the header
   so light hero images don't swallow the text. */
#main-header:not(.et-fixed-header)::before {
    content: "";
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 180px;
    background: linear-gradient(180deg, rgba(0,0,0,0.55) 0%, rgba(0,0,0,0) 100%);
    pointer-events: none;
    z-index: -1;
}
#main-header .logo_container img,
#main-header #top-menu a,
#main-header #top-menu li > a {
    text-shadow: 0 1px 6px rgba(0,0,0,0.7);
}

/* Constrain the site logo. Divi's .logo_container is position:absolute
   full-width, so we restrict its visible width and float the logo image
   hard-left. */
#main-header .logo_container {
    position: absolute !important;
    left: 24px !important;
    top: 0;
    height: 100% !important;
    width: 200px !important;
    max-width: 200px !important;
    display: flex;
    align-items: center;
}
#main-header #logo {
    max-height: 70% !important;
    max-width: 170px !important;
    width: auto !important;
    height: auto !important;
    display: block !important;
    object-fit: contain;
}

/* Keep nav on a single row when possible */
#main-header #top-menu {
    display: flex !important;
    flex-wrap: nowrap !important;
    align-items: center;
}
#main-header #top-menu li {
    font-size: 14px !important;
    padding-right: 18px !important;
    white-space: nowrap;
}

/* Tighten the inner container so logo + nav share the width comfortably */
#main-header #et-top-navigation {
    padding-top: 34px !important;
    padding-right: 30px;
    padding-left: 250px !important;  /* reserves space for absolute logo */
    width: 100%;
    box-sizing: border-box !important;
}
#main-header #et_top_search { display: none !important; }
@media (max-width: 1200px) {
    #main-header #et-top-navigation { padding-left: 210px !important; }
    #main-header #top-menu li { padding-right: 14px !important; font-size: 13px !important; }
}
@media (max-width: 980px) {
    #main-header #et-top-navigation { padding-left: 0 !important; }
}

/* ==========================================================================
   Hero — first section on each page should be full-bleed, no top padding
   ========================================================================== */

.et_pb_section:first-of-type {
    padding-top: 0 !important;
    padding-bottom: 0 !important;
}
.et_pb_section:first-of-type .et_pb_row {
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
}
.et_pb_section:first-of-type .et_pb_fullwidth_image,
.et_pb_section:first-of-type .et_pb_image {
    margin: 0 !important;
}
.et_pb_section:first-of-type .et_pb_fullwidth_image img,
.et_pb_section:first-of-type .et_pb_image img {
    width: 100% !important;
    display: block;
}

/* Hero overlay composition — applies to every page that uses the
   .sa-hero-wrap pattern (home + inner pages). */
.sa-hero-wrap {
    position: relative;
    width: 100%;
    overflow: hidden;
}
.sa-hero-wrap img.sa-hero-bg {
    width: 100%;
    height: auto;
    display: block;
    max-height: 95vh;
    object-fit: cover;
}
.sa-hero-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 140px 8vw 40px;
    color: var(--sa-text);
}
body.home .sa-hero-overlay {
    max-width: 55%;
}
body.home .sa-hero-overlay img.sa-hero-mark {
    width: 340px;
    max-width: 80%;
    margin-bottom: 2rem;
}
/* Inner-page hero overlay — centered title */
.sa-hero-overlay.sa-hero-overlay--center {
    max-width: 100%;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 120px 5vw 40px;
    inset: 0;
}
.sa-hero-overlay.sa-hero-overlay--center h1 {
    color: #fff;
    text-shadow: 0 2px 10px rgba(0,0,0,0.6);
    font-weight: 700;
}
.sa-hero-wrap { overflow: hidden; }
body.home .sa-hero-overlay p {
    font-size: 1.05rem;
    line-height: 1.6;
    max-width: 520px;
    margin-bottom: 1rem;
    text-shadow: 0 1px 6px rgba(0,0,0,0.55);
}

@media (max-width: 980px) {
    body.home #main-header { position: static !important; background: var(--sa-bg) !important; }
    body.home .sa-hero-overlay { position: static; max-width: 100%; padding: 2rem 1rem; }
    body.home .sa-hero-overlay img.sa-hero-mark { width: 240px; }
}

/* ==========================================================================
   Misc page content
   ========================================================================== */

/* Profile card spacing (Meet the Apprentices) */
.sa-profile-card { margin-bottom: 3.5rem; }
.sa-profile-name { font-weight: 700; margin-bottom: 0.25rem; }
.sa-profile-role { color: var(--sa-text-muted); font-style: italic; margin-bottom: 1rem; }

/* Blockquotes */
.et_pb_text_inner blockquote {
    border-left: 3px solid var(--sa-accent);
    padding: 1rem 1.5rem;
    margin: 2rem auto;
    max-width: 720px;
    background: rgba(255,255,255,0.02);
    color: var(--sa-text);
}
.et_pb_text_inner blockquote footer {
    margin-top: .75rem;
    color: var(--sa-text-muted);
    font-style: normal;
}

/* Buttons — keep button text readable on cyan */
.et_pb_button,
.et_pb_button:hover {
    color: #0e0e0e !important;
    background-color: var(--sa-accent) !important;
    border-color: var(--sa-accent) !important;
}
