/*
Theme Name: AMRICC Theme
Theme URI: https://www.amricc.com
Author: Tiago Porter (SO)
Author URI: https://somarketing.com
Description: Custom WordPress theme for AMRICC - Applied Materials Research, Innovation & Commercialisation Company.
Version: 2.2.4
Requires PHP: 7.4
Requires at least: 5.8
Text Domain: amricc
*/

/* ===========================
   CSS Custom Properties
   =========================== */
:root {
    --amricc-orange: #F15A31;
    --amricc-orange-dark: #d94a24;
    --amricc-orange-light: rgba(241, 90, 49, 0.1);
    --amricc-grey-light: #A7A9AC;
    --amricc-grey-dark: #818285;
    --amricc-black: #000000;
    --amricc-white: #FFFFFF;
    --amricc-footer-bg: #2a2a2a;
    --max-width: 1200px;
    --header-height: 130px;
}

/* ===========================
   Reset & Base
   =========================== */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: Arial, Helvetica, sans-serif;
    font-weight: 400;
    color: var(--amricc-black);
    line-height: 1.6;
    background: var(--amricc-white);
    -webkit-font-smoothing: antialiased;
}

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

a {
    color: var(--amricc-orange);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: var(--amricc-orange-dark);
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    color: var(--amricc-orange);
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

h1 { font-size: 2.4rem; margin-bottom: 1rem; }
h2 { font-size: 1.8rem; margin-bottom: 0.8rem; }
h3 { font-size: 1.4rem; margin-bottom: 0.6rem; color: var(--amricc-grey-dark); }
h4 { font-size: 1.2rem; margin-bottom: 0.5rem; color: var(--amricc-grey-dark); }

p {
    margin-bottom: 1rem;
    text-align: justify;
}

ul, ol {
    margin-bottom: 1rem;
    padding-left: 1.5rem;
}

li {
    margin-bottom: 0.3rem;
}

li::marker {
    color: var(--amricc-orange);
}

/* ===========================
   Layout Container
   =========================== */
.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 2rem;
}

/* ===========================
   Header
   =========================== */
.site-header {
    background: var(--amricc-white);
    border-bottom: 2px solid var(--amricc-grey-light);
    position: relative;
    z-index: 10001;
    overflow: hidden;
}

.site-header::before,
.site-header::after {
    content: '';
    position: absolute;
    top: 0;
    height: 100%;
    background-repeat: no-repeat;
    pointer-events: none;
    z-index: 0;
}

.site-header::before {
    left: -115px;
    width: 500px;
    background-image: url('img/AMRICC Asset 2.png');
    background-size: auto 200%;
    background-position: right center;
    transform: scaleX(-1);
}

.site-header::after {
    right: -225px;
    width: 380px;
    background-image: url('img/AMRICC Asset 3.png');
    background-size: auto 160%;
    background-position: bottom left;
}

.header-inner {
    position: relative;
    z-index: 1;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: var(--header-height);
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 2rem;
}

.site-branding {
    order: 1;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.site-branding .main-logo {
    display: block;
}

.site-branding .main-logo img {
    height: 100px;
    width: auto;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.site-branding .main-logo:hover img {
    opacity: 0.8;
    transform: scale(1.03);
}

.partner-logos {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0.5rem;
}

.partner-logo-slot {
    height: 45px;
    display: flex;
    align-items: center;
}

.partner-logo-slot a {
    display: block;
    height: 100%;
    transition: opacity 0.2s ease;
}

.partner-logo-slot a:hover {
    opacity: 0.75;
}

.partner-logo-slot img {
    max-height: 100%;
    width: auto;
    display: block;
}

/* Primary Navigation */
.primary-navigation {
    order: 2;
}

.primary-navigation ul {
    display: flex;
    list-style: none;
    gap: 0.5rem;
    padding: 0;
    margin: 0;
}

.primary-navigation li {
    margin: 0;
}

.primary-navigation a {
    display: block;
    padding: 0.6rem 1.2rem;
    font-weight: 700;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #58595B;
    border-bottom: 3px solid transparent;
    transition: color 0.2s ease, border-color 0.2s ease;
}

.primary-navigation a:hover,
.primary-navigation .current-menu-item a,
.primary-navigation .current_page_item a {
    color: var(--amricc-orange);
    border-bottom-color: var(--amricc-orange);
}

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    order: 0;
}

.menu-toggle span {
    display: block;
    width: 26px;
    height: 3px;
    background: var(--amricc-grey-dark);
    margin: 5px 0;
    border-radius: 2px;
    transition: all 0.3s ease;
}

.menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 6px);
}

.menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -6px);
}

/* ===========================
   Hero Section
   =========================== */
.hero {
    background: var(--amricc-orange);
    color: var(--amricc-white);
    padding: 5rem 0;
    text-align: center;
}

.hero h1 {
    color: var(--amricc-white);
    font-size: 2.8rem;
    margin-bottom: 1rem;
    text-transform: uppercase;
}

.hero .tagline {
    font-size: 1.15rem;
    font-weight: 400;
    opacity: 0.95;
    max-width: 700px;
    margin: 0 auto;
    text-align: center;
    line-height: 1.5;
}

.hero .btn {
    display: inline-block;
    padding: 0.9rem 2.5rem;
    background: var(--amricc-white);
    color: var(--amricc-orange);
    font-weight: 700;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-radius: 4px;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.hero .btn:hover {
    background: rgba(255, 255, 255, 0.9);
    color: var(--amricc-orange-dark);
    transform: translateY(-1px);
}

/* ===========================
   Map Page (Front Page)
   =========================== */
.map-page {
    padding: 0;
    margin: 0;
    line-height: 0;
    font-size: 0;
}

.map-page .ceramics-map-wrap {
    width: 100%;
    font-size: 1rem;
    line-height: 1.5;
}

/* ===========================
   Content Sections
   =========================== */
.content-section {
    padding: 4rem 0;
}

.content-section:nth-child(even) {
    background: transparent;
}

.content-section .section-title {
    text-align: center;
    margin-bottom: 2.5rem;
    position: relative;
    padding-bottom: 1rem;
}

.content-section .section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: var(--amricc-orange);
}

/* Page Content */
.page-content {
    padding: 4rem 0;
}

.page-content .entry-content {
    max-width: 800px;
    margin: 0 auto;
}

/* Page Header */
.page-header {
    background: var(--amricc-orange);
    color: var(--amricc-white);
    padding: 3rem 0;
    text-align: center;
}

.page-header h1 {
    color: var(--amricc-white);
    margin: 0;
}

/* ===========================
   Contact Page
   =========================== */
.contact-layout {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 3rem;
    padding: 4rem 0;
}

.contact-form-area h2 {
    margin-bottom: 1.5rem;
}

.contact-sidebar {
    background: #f8f8f8;
    padding: 2rem;
    border-radius: 6px;
    align-self: start;
}

.contact-sidebar h3 {
    color: var(--amricc-grey-dark);
    margin-bottom: 1.5rem;
    text-transform: uppercase;
}

.contact-detail {
    margin-bottom: 1.2rem;
}

.contact-detail p {
    margin: 0;
    text-align: left;
    color: var(--amricc-grey-dark);
    font-size: 0.95rem;
    line-height: 1.6;
}

.contact-detail a {
    color: var(--amricc-grey-dark);
}

.contact-detail a:hover {
    color: var(--amricc-orange);
}

/* CF7 Form Styling */
.wpcf7 input[type="text"],
.wpcf7 input[type="email"],
.wpcf7 input[type="tel"],
.wpcf7 textarea {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1px solid var(--amricc-grey-light);
    border-radius: 4px;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 0.95rem;
    transition: border-color 0.2s ease;
    background: var(--amricc-white);
}

.wpcf7 input[type="text"]:focus,
.wpcf7 input[type="email"]:focus,
.wpcf7 input[type="tel"]:focus,
.wpcf7 textarea:focus {
    outline: none;
    border-color: var(--amricc-orange);
}

.wpcf7 textarea {
    min-height: 150px;
    resize: vertical;
}

.wpcf7 label {
    display: block;
    margin-bottom: 0.3rem;
    font-weight: 700;
    font-size: 0.85rem;
    text-transform: uppercase;
    color: var(--amricc-grey-dark);
    letter-spacing: 0.03em;
}

.wpcf7 p {
    margin-bottom: 1.2rem;
    text-align: left;
}

.wpcf7 input[type="submit"] {
    display: inline-block;
    padding: 0.85rem 2.5rem;
    background: var(--amricc-orange);
    color: var(--amricc-white);
    border: none;
    border-radius: 4px;
    font-family: Arial, Helvetica, sans-serif;
    font-weight: 700;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    cursor: pointer;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.wpcf7 input[type="submit"]:hover {
    background: var(--amricc-orange-dark);
    transform: translateY(-1px);
}

/* Join Form Sections */
.join-form-section {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--amricc-grey-light);
}

.join-form-section:last-of-type {
    border-bottom: none;
}

.join-form-section h3 {
    color: var(--amricc-grey-dark);
    margin-bottom: 0.75rem;
    font-size: 1.25rem;
}

.join-form-section > label {
    display: block;
    margin-top: 1rem;
    margin-bottom: 0.3rem;
    font-weight: 700;
    font-size: 0.85rem;
    text-transform: uppercase;
    color: var(--amricc-grey-dark);
    letter-spacing: 0.03em;
}

.join-form-section > label:first-of-type {
    margin-top: 0;
}

.join-form-section .wpcf7-form-control-wrap {
    display: block;
    margin-bottom: 0.25rem;
}

.wpcf7 select {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1px solid var(--amricc-grey-light);
    border-radius: 4px;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 0.95rem;
    background: var(--amricc-white);
    transition: border-color 0.2s ease;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23818285' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.8rem center;
    padding-right: 2.5rem;
}

.wpcf7 select:focus {
    outline: none;
    border-color: var(--amricc-orange);
}

.cf7-other-field {
    margin-top: 0.5rem;
    padding: 0.75rem;
    background: #f9f9f9;
    border-radius: 4px;
}

.wpcf7 .wpcf7-checkbox,
.wpcf7 .wpcf7-radio {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 1.5rem;
    margin-top: 0.3rem;
}

.wpcf7 .wpcf7-checkbox .wpcf7-list-item,
.wpcf7 .wpcf7-radio .wpcf7-list-item {
    margin: 0;
    font-size: 0.9rem;
    color: var(--amricc-grey-dark);
}

.wpcf7 .wpcf7-checkbox input[type="checkbox"],
.wpcf7 .wpcf7-radio input[type="radio"] {
    accent-color: var(--amricc-orange);
    margin-right: 0.3rem;
}

.wpcf7 .cm-submit {
    margin-top: 1rem;
}

/* ===========================
   Footer
   =========================== */
.site-footer {
    background: var(--amricc-footer-bg);
    color: var(--amricc-grey-light);
    padding: 3rem 0 0;
}

.footer-inner {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 2.5rem;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 2rem 2.5rem;
}

.footer-col h4 {
    color: var(--amricc-white);
    font-size: 0.95rem;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.footer-col p {
    font-size: 0.9rem;
    text-align: left;
    line-height: 1.7;
    color: var(--amricc-grey-light);
}

.footer-col a {
    color: var(--amricc-grey-light);
}

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

/* Footer Navigation */
.footer-navigation ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-navigation li {
    margin-bottom: 0.5rem;
}

.footer-navigation a {
    display: inline-block;
    font-size: 0.9rem;
    color: var(--amricc-grey-light);
    padding: 0.15rem 0;
    transition: color 0.2s ease, padding-left 0.2s ease;
}

.footer-navigation a:hover {
    color: var(--amricc-orange);
    padding-left: 0.3rem;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 1.2rem 2rem;
    text-align: center;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.4);
    max-width: var(--max-width);
    margin: 0 auto;
}

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

    .contact-layout {
        grid-template-columns: 1fr;
    }

    .contact-sidebar {
        border-left: none;
        border-top: 4px solid var(--amricc-orange);
    }
}

@media (max-width: 768px) {
    :root {
        --header-height: 70px;
    }

    .site-header::before,
    .site-header::after {
        display: none;
    }

    .header-inner {
        height: auto;
        min-height: var(--header-height);
        padding-top: 1rem;
        padding-bottom: 1rem;
    }

    .menu-toggle {
        display: block;
        order: 3;
        margin-left: auto;
    }

    .primary-navigation {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--amricc-white);
        border-bottom: 2px solid var(--amricc-grey-light);
        padding: 1rem;
        z-index: 10001;
    }

    .primary-navigation.active {
        display: block;
    }

    .primary-navigation ul {
        flex-direction: column;
        gap: 0;
    }

    .primary-navigation a {
        padding: 0.8rem 1rem;
        border-radius: 0;
        border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    }

    .site-branding {
        flex-wrap: wrap;
        gap: 0.75rem 1rem;
    }

    .site-branding .main-logo img {
        height: 70px;
    }

    .partner-logos {
        flex-basis: 100%;
        flex-direction: row;
        align-items: center;
        gap: 1rem;
    }

    .partner-logo-slot {
        flex: 1;
        height: 40px;
    }

    .hero {
        padding: 3rem 0;
    }

    .hero h1 {
        font-size: 2rem;
    }

    h1 { font-size: 1.8rem; }
    h2 { font-size: 1.5rem; }

    .footer-inner {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-navigation a:hover {
        padding-left: 0;
    }

    .footer-col p {
        text-align: center;
    }

    .container {
        padding: 0 1.2rem;
    }

    .content-section {
        padding: 2.5rem 0;
    }

    .page-content {
        padding: 2.5rem 0;
    }
}

@media (max-width: 480px) {
    .hero h1 {
        font-size: 1.6rem;
    }

    .hero .tagline {
        font-size: 1rem;
    }
}
