/* ==================== FONT FACES ==================== */
@font-face {
    font-family: 'ITC Garamond Std Book Condensed';
    src: url("font/itc-garamond/ITCGaramondStd-BkCond.eot");
    src: local('ITC Garamond Std Book Condensed'), local('ITCGaramondStd-BkCond'),
        url('font/itc-garamond/ITCGaramondStd-BkCond.eot?#iefix') format('embedded-opentype'),
        url('font/itc-garamond/ITCGaramondStd-BkCond.woff2') format('woff2'),
        url('font/itc-garamond/ITCGaramondStd-BkCond.woff') format('woff'),
        url('font/itc-garamond/ITCGaramondStd-BkCond.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'ITC Garamond Std Book';
    src: url('font/itc-garamond/ITCGaramondStd-Bk.eot');
    src: local('ITC Garamond Std Book'), local('ITCGaramondStd-Bk'),
        url('font/itc-garamond/ITCGaramondStd-Bk.eot?#iefix') format('embedded-opentype'),
        url('font/itc-garamond/ITCGaramondStd-Bk.woff2') format('woff2'),
        url('font/itc-garamond/ITCGaramondStd-Bk.woff') format('woff'),
        url('font/itc-garamond/ITCGaramondStd-Bk.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'ITC Garamond Std Bold Condensed';
    src: url('font/itc-garamond/ITCGaramondStd-BdCondIta.eot');
    font-weight: bold;
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: 'ITC Garamond Std Book Italic';
    src: url('font/itc-garamond/ITCGaramondStd-BkIta.eot');
    font-weight: normal;
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: 'ITC Garamond Std';
    src: url('font/itc-garamond/ITCGaramondStd-Bd.eot');
    src: local('ITC Garamond Std Bold'), local('ITCGaramondStd-Bd'),
        url('font/itc-garamond/ITCGaramondStd-Bd.eot?#iefix') format('embedded-opentype'),
        url('font/itc-garamond/ITCGaramondStd-Bd.woff2') format('woff2'),
        url('font/itc-garamond/ITCGaramondStd-Bd.woff') format('woff'),
        url('font/itc-garamond/ITCGaramondStd-Bd.ttf') format('truetype');
    font-weight: bold;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'ITC Garamond Std';
    src: url('font/itc-garamond/ITCGaramondStd-Lt.eot');
    src: local('ITC Garamond Std Light'), local('ITCGaramondStd-Lt'),
        url('font/itc-garamond/ITCGaramondStd-Lt.eot?#iefix') format('embedded-opentype'),
        url('font/itc-garamond/ITCGaramondStd-Lt.woff2') format('woff2'),
        url('font/itc-garamond/ITCGaramondStd-Lt.woff') format('woff'),
        url('font/itc-garamond/ITCGaramondStd-Lt.ttf') format('truetype');
    font-weight: 300;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'ITC Garamond Std Book Condensed';
    src: url('font/itc-garamond/ITCGaramondStd-BkCondIta.eot');
    src: local('ITC Garamond Std Book Condensed Italic'), local('ITCGaramondStd-BkCondIta'),
        url('font/itc-garamond/ITCGaramondStd-BkCondIta.eot?#iefix') format('embedded-opentype'),
        url('font/itc-garamond/ITCGaramondStd-BkCondIta.woff2') format('woff2'),
        url('font/itc-garamond/ITCGaramondStd-BkCondIta.woff') format('woff'),
        url('font/itc-garamond/ITCGaramondStd-BkCondIta.ttf') format('truetype');
    font-weight: normal;
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: 'ITC Garamond Std';
    src: url('font/itc-garamond/ITCGaramondStd-LtIta.eot');
    src: local('ITC Garamond Std Light Italic'), local('ITCGaramondStd-LtIta'),
        url('font/itc-garamond/ITCGaramondStd-LtIta.eot?#iefix') format('embedded-opentype'),
        url('font/itc-garamond/ITCGaramondStd-LtIta.woff2') format('woff2'),
        url('font/itc-garamond/ITCGaramondStd-LtIta.woff') format('woff'),
        url('font/itc-garamond/ITCGaramondStd-LtIta.ttf') format('truetype');
    font-weight: 300;
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: 'ITC Garamond Std Ultra Condensed';
    src: url('font/itc-garamond/ITCGaramondStd-UltCond.eot');
    src: local('ITC Garamond Std Ultra Condensed'), local('ITCGaramondStd-UltCond'),
        url('font/itc-garamond/ITCGaramondStd-UltCond.eot?#iefix') format('embedded-opentype'),
        url('font/itc-garamond/ITCGaramondStd-UltCond.woff2') format('woff2'),
        url('font/itc-garamond/ITCGaramondStd-UltCond.woff') format('woff'),
        url('font/itc-garamond/ITCGaramondStd-UltCond.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'ITC Garamond Std Light Condensed';
    src: url('font/itc-garamond/ITCGaramondStd-LtCond.eot');
    src: local('ITC Garamond Std Light Condensed'), local('ITCGaramondStd-LtCond'),
        url('font/itc-garamond/ITCGaramondStd-LtCond.eot?#iefix') format('embedded-opentype'),
        url('font/itc-garamond/ITCGaramondStd-LtCond.woff2') format('woff2'),
        url('font/itc-garamond/ITCGaramondStd-LtCond.woff') format('woff'),
        url('font/itc-garamond/ITCGaramondStd-LtCond.ttf') format('truetype');
    font-weight: 300;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'ITC Garamond Std Ultra';
    src: url('font/itc-garamond/ITCGaramondStd-Ult.eot');
    src: local('ITC Garamond Std Ultra'), local('ITCGaramondStd-Ult'),
        url('font/itc-garamond/ITCGaramondStd-Ult.eot?#iefix') format('embedded-opentype'),
        url('font/itc-garamond/ITCGaramondStd-Ult.woff2') format('woff2'),
        url('font/itc-garamond/ITCGaramondStd-Ult.woff') format('woff'),
        url('font/itc-garamond/ITCGaramondStd-Ult.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

/* ==================== CSS VARIABLES FOR THEMING ==================== */
:root {
    bg-primary: #FDF3E7;
}

[data-theme="dark"] {
    bg-primary: #000;
}

background {
	background: #000;
}

[data-theme="dark"] background {
	background: #FDF3E7;
}

/* ==================== GLOBAL STYLES ==================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Lato', sans-serif;
    background-color: var(--bg-primary);
    color: #000000;
    transition: background-color 0.3s ease, color 0.3s ease;
    overflow-x: hidden;
}

[data-theme="dark"] body {
    color: #E0E0E0;
}

.serif {
    font-family: 'EB Garamond', 'Georgia', serif;
}

.condensed {
    font-family: 'ITC Gararmond Std Book Condensed', 'Oswald', 'Arial Narrow', sans-serif;
}

/* ==================== HEADER ==================== */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 25px 40px;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to bottom, 
        rgba(253, 243, 231, 0.5) 0%, 
        rgba(253, 243, 231, 0.3) 70%, 
        rgba(253, 243, 231, 0) 100%); /* ✅ CHANGED to gradient fade */
    z-index: 100;
    transition: all 0.3s ease;
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    padding-bottom: 40px; /* ✅ ADD extra padding for fade space */
}

[data-theme="dark"] header {
    background: linear-gradient(to bottom, 
        rgba(0, 0, 0, 0.5) 0%, 
        rgba(0, 0, 0, 0.3) 70%, 
        rgba(0, 0, 0, 0) 100%);
}

header.hidden {
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none; /* Optional: prevent clicking when hidden */
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.logo {
    display: block;
    transition: opacity 0.3s ease;
}

.logo:hover {
    opacity: 0.8;
}

.logo img {
	max-height: 50px;
	background-size: cover;
}

nav {
    display: flex;
    gap: 50px;
    background: rgba(0, 0, 0, 0);
    padding: 10px 40px;
	cursor: pointer;
    box-shadow: 0px 4px 4px rgba(255, 255, 255, 0.25) inset;
    border-radius: 102px;
}

nav a {
    color: #4F7A3E;
    text-decoration: none;
    font-size: clamp(16px);
    font-family: 'ITC Garamond Std', serif;
    font-weight: bold;
    transition: opacity 0.3s ease;
}

[data-theme="dark"] nav a {
    color: #FDF3E7;
}

nav a:hover {
	color: #A84B3D;
	text-shadow: #A9B8A3 100%;
	font-family: 'ITC Garamond Std', serif;
	font-weight: bold;
}

[data-theme="dark"] nav a:hover {
	color: #53664B;
}

/* Theme Toggle */
.theme-toggle {
    width: 61px;
    height: 32px;
    background: #83997B;
    border-radius: 37px;
    position: relative;
    cursor: pointer;
    box-shadow: 0px 4px 4px rgba(0, 0, 0, 0.1);
    transition: background 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 6px;
}

[data-theme="dark"] .theme-toggle {
    background-color: #E8E8E8;
}

.theme-icon {
    width: 18px;
    height: 18px;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.theme-icon img {
    width: 16px;
    height: 16px;
    display: block;
    transition: filter 0.3s ease;
}

/* Light mode: icons are white */
.theme-icon img {
    filter: brightness(0) invert(1);
}

/* Dark mode: icons are black */
[data-theme="dark"] .theme-icon img {
    filter: brightness(0) invert(0);
}

.theme-toggle-slider {
    width: 28px;
    height: 28px;
    background: rgba(255, 255, 255, 0.3);
    cursor: pointer;
    box-shadow: 0px 2px 4px rgba(0, 0, 0, 0.2);
    border-radius: 50%;
    position: absolute;
    left: 2px;
    top: 2px;
    transition: left 0.3s ease, background 0.3s ease;
    z-index: 2;
}

[data-theme="dark"] .theme-toggle-slider {
    left: 31px;
    background: rgba(0, 0, 0, 0.2);
}

/* ==================== HERO SECTION ==================== */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 12vh 5% 6vh;
    overflow: visible;
}

.hero-bg-image {
    position: absolute;
	background-image: url("aspac-images/home-hero.jpg");
	background-size: cover;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
	filter: blur(5.35px);
    z-index: 0;
}

.hero-content {
    max-width: 90%;
    position: absolute;
}

.hero h1 {
    font-size: 80px;
    font-weight: bolder;
	font-family:'ITC Garamond Std', serif; 
	margin-top: 5%;
    color: #FDF3E7;
}

.hero p {
    font-size: 32px;
	font-family:'ITC Garamond Std Book Condensed', serif;
    color: #FDF3E7;
    margin-bottom: 10%;
}

.cta-button {
    background: rgba(0, 0, 0, 0);
    color: #FDF3E7;
    padding: 12px 40px;
    border-radius: 20px;
    border: none;
    font-size: 16px;
    font-weight: 500;
    font-family: 'Lato', sans-serif;
    cursor: pointer;
    box-shadow: 0px 4px 4px rgba(255, 255, 255, 0.25) inset;
    transition: all 0.3s ease;
    text-decoration: none; /* ✅ ADD THIS */
    display: inline-block; /* ✅ ADD THIS */
}

.cta-button:hover {
    background: rgba(255, 255, 255, 0.1);
	font-family: 'Lato', sans-serif;
	font-weight: bold;
    transform: translateY(-2px);
}

/* ==================== TESTIMONIALS SECTION ==================== */
/* Or add padding to testimonials to overlap */
.testimonials {
    padding: 10vh 5%;
    background: #A9B8A3;
    text-align: center;
    margin: 0 0 8vh 0;
    transition: background-color 0.3s ease;
    position: relative;
    z-index: 2;
    margin-top: 0; /* CHANGE from 8vh to 0 */
}

/* Blurred gradient box behind testimonials */
.testimonials::before {
    content: '';
    position: absolute;
    top: -25%;
    left: -15%;
    right: -15%;
    bottom: -30%;
    background: #A9B8A3;
    filter: blur(42.7px);
    z-index: -1;
    transition: background 0.3s ease;
}

[data-theme="dark"] .testimonials {
    background: #292929;
}

[data-theme="dark"] .testimonials::before {
    background: #292929;
}

.testimonials h3 {
    font-size: 20px;
    font-weight: 300;
    color: white;
    font-family: 'Lato', sans-serif;
    font-weight: lighter;
    margin-bottom: 1%;
}

.testimonials h2 {
    font-size: 36px;
    font-weight: 400;
    color: white;
    font-family: 'ITC Garamond Std Book', serif;
    margin-bottom: 60px;
}

.testimonial-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    max-width: 90%;
    margin: 0 auto;
}

.testimonial-card {
    background: #F6F4F4;
    border-radius: 10px;
    padding: 30px;
    text-align: left;
    transition: transform 0.3s ease, background-color 0.3s ease;
}

.testimonial-author {
    display: inline-block;
    border: 0.5px solid black;
    color: black;
    border-radius: 37px;
    padding: 5px 15px;
    font-size: clamp(11px);
    font-weight: 300;
    margin-bottom: 30px;
}

.testimonial-text {
    font-size: clamp(20px);
    font-family: 'ITC Garamond Std', serif;
    font-weight: lighter;
    line-height: 1.4;
    color: black;
}


/* ==================== VIDEO SECTION ==================== */
.video-section {
    padding: 0;
    background: #FDF3E7;
}

[data-theme="dark"] .video-section {
    background: #040404;
}

.video-container {
    width: clamp(70vh);
    height: auto;
	padding-left: 10%;
	padding-right: 10%;
	padding-top: 8%;
	padding-bottom: 5%;
    position: relative;
    display:block;
    align-items: center;
    justify-content: center;
    overflow:visible;
}

.video-player {
    position: relative;
	animation: auto;
    top: 20%;
    width: 100%;
    height: 58%;
    object-fit:fill;
	border-radius: 20px;
}


/* ==================== SERVICES SECTION ==================== */
.services {
    display: grid;
    grid-template-columns: repeat(3, 33.333%);
    grid-template-rows: repeat(2, 40%);
    max-width: 100%;
    position: relative;
    z-index: 1; /* ✅ CHANGED from 10 to 1 - Services appear below the footer */
    margin-bottom: -225px; /* Half of service card min-height to create overlap */
}

.service-card {
    padding: 10%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 450px;
	max-height: 100%;
    transition: background-color 0.3s ease;
}

/* ✅ ADDED - Make bottom row cards taller */
.service-card:nth-child(4),
.service-card:nth-child(5),
.service-card:nth-child(6) {
    min-height: 600px;
}

.service-card.pain-management {
    background: #A9C3D3;
}

[data-theme="dark"] .service-card.pain-management {
    background: #D9D9D9;
}

.service-card.spiritual-care {
    background: #4B5563;
}

[data-theme="dark"] .service-card.spiritual-care {
    background: #D9D9D9;
}

.service-card.emotional-support {
    background: #CE6757;
	padding-top: 10px;
}

[data-theme="dark"] .service-card.emotional-support {
    background: #D9D9D9;
}

.service-content h3 {
    font-size: 42px;
    font-weight: 800;
    line-height: 1.1;
    color: #F6F4F4;
	font-family: 'ITC Garamond Std Ultra', serif;
    margin-bottom: 20px;
}

.service-content p {
    font-size: 18px;
    font-weight: 300;
	font-family: 'Lato', sans-serif;
    color: #F6F4F4;
    line-height: 1.5;
}


.service-content h3 {
	color: #fff;
}

.service-content p {
	color: #fff;
}

[data-theme="dark"] .service-content h3 {
	color: #292929;
}

[data-theme="dark"] .service-content p {
	color: #292929;
}

.service-image-card {
    background: #888;
	max-height:600px; 
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden; /* ✅ ADDED: To contain images */
}

/* Make bottom row image cards match the height of bottom row text cards */
.service-image-card:nth-child(4),
.service-image-card:nth-child(5),
.service-image-card:nth-child(6) {
    min-height: 600px;
}

.service-image {
    width: 100%;
    height: 100%;
    object-fit: cover; /* ✅ ADDED: Ensures images fill the space properly */
    /* ✅ REMOVED: background: #666; (no longer needed with img tags) */
}

/* ==================== FOOTER ==================== */
footer {
    background: #A9B8A3;
    padding: 8% 6% 0%;
    color: white;
    transition: background-color 0.3s ease;
    border-top-left-radius: 60px;
    border-top-right-radius: 60px;
    display: flex;
    flex-direction: column;
    gap: 35px;
    position: relative;
    z-index: 10;
    padding-bottom: 2%;
}

[data-theme="dark"] footer {
    background: #292929;
}

/* 3-column layout container */
.footer-content {
    display: grid;
    grid-template-columns: 45% 20% 20%;
    column-gap: 5%;
    align-items: start;
}

.footer-newsletter {
    display: flex;
    flex-direction: column;
    align-items: center;
	text-align: center;
    justify-content: flex-start;
}

.footer-newsletter h2,
.footer-newsletter a {
    font-size: clamp(32px, 4vw, 48px);
    font-family: 'ITC Garamond Std Book Condensed', serif;
    margin-bottom: 30%;
    letter-spacing: -1%;
    text-align: center;
    line-height: 0.95;
}

/* Email input with submit button - centered container */
.email-form {
	
    position: relative;
    width: 60%;
    margin-top: 5%;
}

.email-input {
    width: 100%;
    padding: 3% 12% 3% 5%;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 25px;
    color: white;
    font-size: clamp(12px, 1vw, 14px);
    font-family: 'Lato', sans-serif;
    font-weight: 300;
    letter-spacing: 0.7px;
}

.email-input::placeholder {
    color: white;
    opacity: 0.7;
}

/* Email validation: invalid state */
.email-input:invalid {
    border-color: rgba(255, 255, 255, 0.3);
}

/* Email validation: valid state */
.email-input:valid {
    border-color: rgba(255, 255, 255, 0.5);
}

.email-submit {
    position: absolute;
    right: 3%;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: white;
    cursor: pointer;
    font-size: clamp(16px, 1.2vw, 20px);
    padding: 2%;
    opacity: 0;
    pointer-events: none;
    visibility: hidden;
    line-height: 1;
    display: none; /* ✅ ADD THIS - completely hide it */
    align-items: center;
    justify-content: center;
}

/* Show submit button only when email is valid */
.email-input:valid + .email-submit {
    opacity: 1;
    pointer-events: auto;
    visibility: visible;
    display: flex; /* ✅ ADD THIS - show it when valid */
}

.email-submit:hover {
    opacity: 0.7;
}

.footer-grid {
    display: contents;
}

.footer-menu {
    text-align: left;
    margin-left: 20%;
}

.footer-support {
    text-align: left;
}

.footer-menu h3,
.footer-support h3 {
    font-size: clamp(16px, 1.5vw, 20px);
    margin-bottom: 12px;
    font-family: 'ITC Garamond Std Book Condensed', serif;
}

.footer-menu ul,
.footer-support ul {
    list-style: none;
}

.footer-menu ul li,
.footer-support ul li {
    text-align: left;
}

.footer-menu ul li a,
.footer-support ul li a {
    color: white;
    text-decoration: none;
    font-size: clamp(13px, 1.1vw, 15px);
    font-weight: 300;
    line-height: 1.8;
    transition: opacity 0.3s ease;
}

.footer-menu ul li a:hover,
.footer-support ul li a:hover {
    opacity: 0.7;
}

.footer-support .address {
    font-size: clamp(13px, 1.1vw, 15px);
    font-weight: 300;
    color: white;
}

/* Social icons - above divider */
.social-icons {
    display: flex;
    gap: 2%;
    align-items: center;
    justify-content: flex-end;
}

.social-icon {
    width: clamp(20px, 1.8vw, 24px);
    height: clamp(20px, 1.8vw, 24px);
    border-radius: 3px;
    cursor: pointer;
    transition: opacity 0.3s ease;
    position: relative;
}

.social-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.social-icon:hover {
    opacity: 0.7;
}

.footer-divider {
    width: 100%;
    height: 1px;
    background: white;
    opacity: 0.3;
    margin: 0;
}

/* Copyright - centered, below divider */
.footer-bottom {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
	margin-bottom: 2%;
}

.copyright {
    font-size: 10px;
	font-family: 'Lato', sans-serif;
    text-align: center;
}


/* ==================== SCROLL TO TOP BUTTON ==================== */
.scroll-top {
    position: fixed;
    bottom: 40px;
    right: 40px;
    width: 50px;
    height: 50px;
   	cursor: pointer;
    box-shadow: 0px 4px 4px rgba(255, 255, 255, 0.25) inset;
    border: none;
    border-radius: 50%;
    font-family: 'Lato', sans-serif;
	font-size: 20px;
	transform: rotate(-0.25turn);
    font-weight: 500;
    opacity: 0;
    visibility: hidden;
    transition: all 300ms ease-in, 300ms ease-out;
    z-index: 99;
    display: flex;
    align-items: center;
    justify-content: center;
}

[data-theme="dark"] .scroll-top {
	transform: rotate(-0.25turn);
    background: rgba(#C2C2C2);
}

.scroll-top.visible {
    opacity: 40%;
	transform: rotate(-0.25turn);
    visibility: visible;
}

.scroll-top:hover {
    opacity: 70%;
	transform: rotate(-0.25turn);
}

[data-theme="dark"] .scroll-top:hover {
    background: rgba(#C2C2C2);
}

/* ==================== RESPONSIVE DESIGN ==================== */
@media (max-width: 1200px) {
    .services {
        grid-template-columns: 1fr;
        grid-template-rows: auto;
    }
}

@media (max-width: 1024px) {
    .hero h1 {
        font-size: 60px;
    }
    
    .hero p {
        font-size: 24px;
    }
    
    .testimonial-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
}

@media (max-width: 768px) {
    header {
        flex-direction: column;
        gap: 20px;
        padding: 15px 20px;
    }
    
    nav {
        gap: 20px;
        padding: 8px 20px;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .hero {
        padding: 100px 20px 40px;
    }
    
    .hero h1 {
        font-size: 40px;
    }
    
    .hero p {
        font-size: 18px;
    }
    
    .service-content h3 {
        font-size: 32px;
    }
    
    .footer-section h2 {
        font-size: 32px;
    }
}