/*
Theme Name: REA Theme
Theme URI: https://refugee-education.org.au
Author: Refugee Education Australia
Author URI: https://refugee-education.org.au
Description: Custom WordPress theme for Refugee Education Australia. Built for Elementor page building with REA branding presets — fonts, colours, header with top bar navigation, compact footer, and consistent styling across all pages.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: rea-theme
Tags: custom-menu, custom-logo, elementor, education, charity
*/


/* ==========================================================================
   CSS RESET & BASE
   ========================================================================== */

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    scroll-behavior: smooth;
}

body {
    font-family: "Open Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 1rem;
    line-height: 1.6;
    color: #333333;
    background-color: #FBF3E2;
}

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

a {
    color: #017A8F;
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: #FF7A40;
}


/* ==========================================================================
   REA BRAND COLOURS
   --rea-teal:       #017A8F   (primary - headings, links, nav)
   --rea-orange:     #FF7A40   (accent - hover, CTA, hero backgrounds)
   --rea-orange-deep:#E86A30   (darker orange for headers)
   --rea-cream:      #FBF3E2   (page background)
   --rea-gold:       #FBC02D   (highlights)
   --rea-dark:       #2C2C2C   (body text, footer background)
   --rea-white:      #FFFFFF
   --rea-light-grey: #F5F5F5
   ========================================================================== */

:root {
    --rea-teal: #017A8F;
    --rea-orange: #FF7A40;
    --rea-orange-deep: #E86A30;
    --rea-cream: #FBF3E2;
    --rea-gold: #FBC02D;
    --rea-dark: #2C2C2C;
    --rea-white: #FFFFFF;
    --rea-light-grey: #F5F5F5;
}


/* ==========================================================================
   TYPOGRAPHY
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Lato:wght@300;400;700;900&family=Open+Sans:wght@300;400;600;700&display=swap');

h1, h2, h3, h4, h5, h6 {
    font-family: "Lato", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--rea-teal);
    line-height: 1.3;
    margin-bottom: 0.5em;
    font-weight: 700;
}

h1 { font-size: 2.25rem; }
h2 { font-size: 1.75rem; }
h3 { font-size: 1.375rem; }
h4 { font-size: 1.125rem; }
h5 { font-size: 1rem; }
h6 { font-size: 0.875rem; }

p {
    margin-bottom: 1em;
}

strong, b {
    font-weight: 700;
}


/* ==========================================================================
   LAYOUT
   ========================================================================== */

.rea-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.site-content {
    min-height: 60vh;
}


/* ==========================================================================
   TOP BAR  (About | News | Contact)
   ========================================================================== */

.rea-top-bar {
    background-color: var(--rea-white);
    border-bottom: 1px solid #e8e8e8;
    padding: 6px 0;
    font-size: 13px;
}

.rea-top-bar .rea-container {
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

.rea-top-bar-menu {
    list-style: none;
    display: flex;
    gap: 24px;
    margin: 0;
    padding: 0;
}

.rea-top-bar-menu li a {
    color: var(--rea-teal);
    font-family: "Open Sans", sans-serif;
    font-weight: 600;
    font-size: 13px;
    letter-spacing: 0.3px;
    transition: color 0.2s ease;
}

.rea-top-bar-menu li a:hover {
    color: var(--rea-orange);
}


/* ==========================================================================
   MAIN NAVIGATION
   ========================================================================== */

.rea-navbar {
    background-color: var(--rea-white);
    padding: 10px 0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.06);
    position: relative;
    z-index: 1000;
}

.rea-navbar .rea-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Logo */
.rea-logo img,
.rea-logo .custom-logo {
    height: 75px;
    width: auto;
    max-height: 75px;
}

.rea-logo a {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.rea-logo .site-title {
    font-family: "Lato", sans-serif;
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--rea-teal);
    line-height: 1.3;
}

/* Desktop menu */
.rea-nav-menu {
    list-style: none;
    display: flex;
    gap: 8px;
    margin: 0;
    padding: 0;
    align-items: center;
}

.rea-nav-menu > li {
    position: relative;
}

.rea-nav-menu > li > a {
    font-family: "Lato", sans-serif;
    font-size: 16px;
    font-weight: 500;
    color: var(--rea-teal);
    padding: 10px 14px;
    display: block;
    border-radius: 4px;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.rea-nav-menu > li > a:hover,
.rea-nav-menu > li.current-menu-item > a,
.rea-nav-menu > li.current-menu-ancestor > a {
    color: #F66E22;
    background-color: rgba(246, 110, 34, 0.06);
}

/* Dropdown indicator */
.rea-nav-menu > li.menu-item-has-children > a::after {
    content: "";
    display: inline-block;
    width: 0;
    height: 0;
    margin-left: 6px;
    vertical-align: middle;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 4px solid currentColor;
}

/* Dropdown menus */
.rea-nav-menu .sub-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 280px;
    background: var(--rea-white);
    border: 1px solid #e8e8e8;
    border-radius: 6px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    padding: 8px 0;
    list-style: none;
    z-index: 1001;
}

.rea-nav-menu > li:hover > .sub-menu {
    display: block;
}

.rea-nav-menu .sub-menu li a {
    display: block;
    padding: 8px 20px;
    font-size: 13px;
    font-weight: 400;
    color: #333;
    transition: background-color 0.15s ease;
}

.rea-nav-menu .sub-menu li a:hover {
    background-color: var(--rea-cream);
    color: var(--rea-orange);
}

/* Sub-sub menus (grandchildren) */
.rea-nav-menu .sub-menu .sub-menu {
    top: 0;
    left: 100%;
    margin-left: 0;
}

.rea-nav-menu .sub-menu li.menu-item-has-children > a::after {
    content: "";
    float: right;
    margin-top: 6px;
    border-top: 4px solid transparent;
    border-bottom: 4px solid transparent;
    border-left: 4px solid currentColor;
}

/* Mobile menu toggle */
.rea-menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    color: var(--rea-teal);
}

.rea-menu-toggle svg {
    width: 28px;
    height: 28px;
}


/* ==========================================================================
   PAGE HEADER (Orange banner on inner pages)
   ========================================================================== */

.rea-page-header {
    background-color: var(--rea-orange);
    padding: 25px 0;
    text-align: center;
}

.rea-page-header h1 {
    font-family: "Lato", sans-serif;
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--rea-white);
    margin: 0;
    line-height: 1.3;
    word-wrap: break-word;
}

/* On homepage, no page header banner */
body.home .rea-page-header {
    display: none;
}


/* ==========================================================================
   CONTENT AREA
   ========================================================================== */

.site-content {
    padding: 40px 0;
}

.site-content .rea-container {
    max-width: 1200px;
}

/* Default entry content styling */
.entry-content h1,
.entry-content h2,
.entry-content h3,
.entry-content h4 {
    margin-top: 1.5em;
    margin-bottom: 0.5em;
}

.entry-content ul,
.entry-content ol {
    margin-bottom: 1em;
    padding-left: 1.5em;
}

.entry-content li {
    margin-bottom: 0.3em;
}


/* ==========================================================================
   FOOTER
   ========================================================================== */

.rea-footer {
    background-color: var(--rea-dark);
    color: #cccccc;
    padding: 30px 0 15px;
    font-size: 14px;
}

.rea-footer a {
    color: #dddddd;
    transition: color 0.2s ease;
}

.rea-footer a:hover {
    color: var(--rea-orange);
}

.rea-footer-inner {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 30px;
    margin-bottom: 25px;
}

.rea-footer h4 {
    color: var(--rea-white);
    font-size: 1rem;
    margin-bottom: 12px;
    font-family: "Lato", sans-serif;
}

.rea-footer-widget {
    line-height: 1.6;
}

.rea-footer-widget ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.rea-footer-widget ul li {
    margin-bottom: 6px;
}

.rea-footer-bottom {
    border-top: 1px solid #444;
    padding-top: 15px;
    text-align: center;
    font-size: 12px;
    color: #999;
}

.rea-footer-bottom a {
    color: #bbb;
}

/* Social icons in footer */
.rea-social-links {
    list-style: none;
    display: flex;
    gap: 12px;
    padding: 0;
    margin: 0;
}

.rea-social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.1);
    color: #ddd;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.rea-social-links a:hover {
    background-color: var(--rea-orange);
    color: var(--rea-white);
}


/* ==========================================================================
   BUTTONS (base styles for Elementor and manual use)
   ========================================================================== */

.rea-button,
.wp-block-button__link {
    display: inline-block;
    font-family: "Open Sans", sans-serif;
    font-weight: 600;
    font-size: 14px;
    padding: 12px 28px;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    text-decoration: none;
    transition: background-color 0.2s ease, transform 0.1s ease;
}

.rea-button-primary {
    background-color: var(--rea-teal);
    color: var(--rea-white);
}

.rea-button-primary:hover {
    background-color: #016677;
    color: var(--rea-white);
    transform: translateY(-1px);
}

.rea-button-accent {
    background-color: var(--rea-orange);
    color: var(--rea-white);
}

.rea-button-accent:hover {
    background-color: var(--rea-orange-deep);
    color: var(--rea-white);
    transform: translateY(-1px);
}

.rea-button-outline {
    background-color: transparent;
    color: var(--rea-teal);
    border: 2px solid var(--rea-teal);
}

.rea-button-outline:hover {
    background-color: var(--rea-teal);
    color: var(--rea-white);
}


/* ==========================================================================
   CARDS (for CoP, For Students, Resources landing pages)
   ========================================================================== */

.rea-card {
    background: var(--rea-white);
    border-radius: 10px;
    padding: 30px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.rea-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
}

.rea-card h3 {
    color: var(--rea-teal);
    margin-bottom: 10px;
}

.rea-card p {
    color: #555;
    font-size: 14px;
    line-height: 1.6;
}

.rea-cards-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
    margin: 30px 0;
}


/* ==========================================================================
   BLOG / NEWS
   ========================================================================== */

.rea-post-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
}

.rea-post-card {
    background: var(--rea-white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.rea-post-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.rea-post-card-body {
    padding: 20px;
}

.rea-post-card-body h3 {
    font-size: 1.125rem;
    margin-bottom: 8px;
}

.rea-post-card-body .post-date {
    font-size: 12px;
    color: #999;
    margin-bottom: 8px;
}


/* ==========================================================================
   RESPONSIVE
   ========================================================================== */

@media (max-width: 992px) {
    .rea-footer-inner {
        grid-template-columns: 1fr 1fr;
    }

    .rea-cards-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    /* Show hamburger, hide desktop nav */
    .rea-menu-toggle {
        display: block;
    }

    .rea-nav-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--rea-white);
        flex-direction: column;
        padding: 16px 0;
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
        gap: 0;
    }

    .rea-nav-menu.is-open {
        display: flex;
    }

    .rea-nav-menu > li > a {
        padding: 12px 20px;
        border-radius: 0;
    }

    .rea-nav-menu .sub-menu {
        position: static;
        box-shadow: none;
        border: none;
        border-radius: 0;
        padding-left: 20px;
        display: none;
    }

    .rea-nav-menu > li.menu-item-has-children.is-open > .sub-menu {
        display: block;
    }

    .rea-footer-inner {
        grid-template-columns: 1fr;
    }

    h1 { font-size: 1.75rem; }
    h2 { font-size: 1.375rem; }

    .rea-logo img,
    .rea-logo .custom-logo {
        height: 55px;
        max-height: 55px;
    }
}


/* ==========================================================================
   HERO SECTION (Homepage)
   ========================================================================== */

.rea-hero-circle-img img,
img.rea-hero-circle-img {
    border-radius: 50% !important;
    object-fit: cover;
    width: 420px;
    height: 420px;
    box-shadow: 0 8px 32px rgba(1, 122, 143, 0.15);
}

@media (max-width: 768px) {
    .rea-hero-circle-img img,
    img.rea-hero-circle-img {
        width: 280px;
        height: 280px;
        margin: 0 auto;
    }
}
