/* Global & Font Definitions */
@font-face {
    font-family: 'Euclid Circular A';
    src: url('../fonts/EuclidCircularA-Light.woff2') format('woff2');
    font-weight: 300;
    font-style: normal;
}

@font-face {
    font-family: 'Euclid Circular A';
    src: url('../fonts/EuclidCircularA-Regular.woff2') format('woff2');
    font-weight: 400;
    font-style: normal;
}

@font-face {
    font-family: 'Euclid Circular A';
    src: url('../fonts/EuclidCircularA-SemiBold.woff2') format('woff2');
    font-weight: 600;
    font-style: normal;
}

:root {
    --text-color: #1a2a40;
    --nav-height: 80px;
    --nav-text-color: #ffffff;
    --bg-enquiries: #FDD6AF;
}

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

body {
    font-family: 'Euclid Circular A', sans-serif;
    color: var(--text-color);
    overflow: hidden;
    background-color: var(--bg-enquiries);
    touch-action: manipulation;
}

#loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    height: 100dvh;
    background-color: transparent;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    transition: opacity 1s ease-in-out, visibility 1s ease-in-out;
}

#loading-screen.hidden {
    opacity: 0;
    visibility: hidden;
}

.loading-logo {
    width: 824px;
    max-width: calc(100% - 40px);
}

#app {
    position: relative;
    width: 100%;
    height: 100vh;
    height: 100dvh;
}

.page-section {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.8s ease-in-out, visibility 0.8s ease-in-out;
    z-index: 1;
}

.page-section.active {
    opacity: 1;
    visibility: visible;
    z-index: 2;
}

#home {
    background-color: transparent;
}

#ripple-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url('../images/background.png');
    background-size: cover;
    background-position: center;
    z-index: 1;
}

@media (orientation: portrait) {
    #ripple-background {
        bottom: -25%;
        right: -10%;
    }
}

@media (orientation: landscape) {
    #ripple-background {
        right: -25%;
        bottom: -10%;
    }
}

.home-content {
    position: absolute;
    bottom: 100px;
    left: 5vw;
    z-index: 2;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 1s ease-in-out 0.5s, transform 1s ease-out 0.5s;
    max-width: 800px;
    pointer-events: none;
}

body.loaded .page-section.active .home-content {
    opacity: 1;
    transform: translateY(0);
}

.home-content h1 {
    font-size: 66px;
    font-weight: 300;
    line-height: 68px;
    margin-bottom: 1.5rem;
    letter-spacing: -0.02em;
}

.home-content p {
    font-size: 20px;
    font-weight: 300;
}

#gallery {
    background-color: #000;
}

.gallery-container {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.gallery-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1s ease-in-out;
}

.gallery-image.active {
    opacity: 1;
}

.gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: calc(100% - var(--nav-height));
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    z-index: 10;
    color: white;
}

#gallery-caption {

    font-size: 17px;
    font-weight: 300;
    max-width: 80%;
    text-shadow: none;
    margin-bottom: 3vh;
    margin-left: 5vw;
}

.gallery-controls {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    transform: translateY(-50%);
    display: flex;
    justify-content: space-between;
    padding: 0 5vw;
    pointer-events: none;
}

.nav-btn {
    pointer-events: auto;
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.6);
    border-radius: 50%;
    width: 35px;
    height: 35px;
    display: flex;
    justify-content: center;
    align-items: center;
    color: white;
    cursor: pointer;
    transition: background-color 0.3s, border-color 0.3s;
}

.nav-btn:hover {
    background-color: transparent;
    border-color: white;
}

.nav-btn svg {
    width: 24px;
    height: 24px;
}

#enquiries {
    background-color: var(--bg-enquiries);
    display: flex;
    justify-content: center;
    align-items: center;
    padding-bottom: var(--nav-height);
}

.enquiries-container {
    display: flex;
    justify-content: center;
    gap: 0;
    max-width: 866px;
    width: 100%;
}

.contact-column {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.newmark-column {
    width: 195px;
    margin-right: 21px;
}

.jll-column {
    width: 275px;
    padding-right: 22px;
}

.stanhope-column {
    width: 330px;
    padding-left: 22px;
    position: relative;
}

.stanhope-column::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    width: 1px;
    background-color: white;
}

.logo-wrapper {
    height: 50px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.stanhope-column .logo-wrapper {
    justify-content: flex-start;
}

.contact-logo {
    object-fit: contain;
    object-position: left;
    height: auto;
}

.contact-logo.newmark {
    width: 160px;
}

.contact-logo.jll {
    width: 111px;
}

.contact-logo.stanhope {
    width: 160px;
}

.contact-person {
    display: flex;
    flex-direction: column;
    font-size: 16px;
    line-height: 24px;
    font-weight: 400;
}

.contact-person strong {
    font-weight: 600;
}

.contact-person a {
    color: var(--text-color);
    text-decoration: none;
    transition: opacity 0.2s;
}

.contact-person a:hover {
    opacity: 0.7;
}

.stanhope-intro {
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 5px;
}

/* Navigation Bar */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: var(--nav-height);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 5vw;
    z-index: 100;
    pointer-events: none;

    background: transparent;
    transform: translateY(100%);
    transition: transform 1s ease-in-out;
}

#terms {
    background-color: var(--bg-enquiries);
    display: flex;
    justify-content: center;
    align-items: flex-start;
}

.terms-container {
    width: 100%;
    height: calc(100vh - var(--nav-height));
    height: calc(100dvh - var(--nav-height));
    padding: 4.12vw 5vw 3.66vw;
    display: flex;
    flex-direction: column;
}

.terms-title {
    font-size: 66px;
    font-weight: 300;
    margin-bottom: 4.12vw;
    color: var(--text-color);
}

.terms-content-area {
    display: grid;
    grid-template-columns: 14.5rem 1fr;
    grid-template-rows: repeat(10, min-content) 1fr;
    column-gap: 8vw;
    row-gap: 0;
    flex: 1;
    min-height: 0;
}

.terms-tab {
    background: transparent;
    border: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.7);
    color: var(--text-color);
    font-family: inherit;
    font-size: 21px;
    font-weight: 300;
    padding: 11px 0;
    display: flex;
    justify-content: flex-start;
    gap: 8px;
    align-items: center;
    cursor: pointer;
    text-align: left;
    transition: opacity 0.3s ease;
    grid-column: 1;
    align-self: start;
}

.terms-tab:first-of-type {
    border-top: 1px solid rgba(255, 255, 255, 0.7);
}

.terms-tab:hover {
    opacity: 0.7;
}

.terms-pane {
    grid-column: 2;
    grid-row: 1 / -1;
    overflow-y: auto;
    padding-right: 6.59vw;
    font-size: 16px;
    line-height: 1.5;
    font-weight: 300;
    display: none;
}

.terms-pane.active {
    display: block;
}

.terms-pane::-webkit-scrollbar {
    width: 10px;
}

.terms-pane::-webkit-scrollbar-track {
    background: transparent;
    border: 1px solid #ffffff;
    border-radius: 10px;
    margin-top: 10px;
    margin-bottom: 10px;
}

.terms-pane::-webkit-scrollbar-thumb {
    background: #ffffff;
    border-radius: 10px;
}

.terms-pane h3,
.terms-pane h2 {
    font-size: 24px;
    font-weight: 300;
    margin-bottom: 20px;
    margin-top: 0;
}

.terms-pane p,
.terms-pane ul,
.terms-pane ol {
    margin-bottom: 15px;
}

.terms-pane ul,
.terms-pane ol {
    padding-left: 20px;
}

.terms-pane li {
    margin-bottom: 5px;
}

.terms-pane a {
    color: #344e76;
    text-decoration: underline;
    transition: color 0.2s ease-in-out;
}

.terms-pane a:hover {
    color: #4a72ad;
}

body.loaded .bottom-nav {
    transform: translateY(0);
}

.nav-left {

    display: flex;
    gap: 4rem;
}

.nav-link {
    color: inherit;
    text-decoration: none;
    font-size: 14px;
    font-weight: 300;
    text-transform: capitalize;
    position: relative;
    transition: opacity 0.3s;
}

.nav-link:hover {
    opacity: 0.8;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 100%;
    height: 1px;
    background-color: inherit;
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
    transform: scaleX(1);
    transform-origin: left;
}

.nav-logo {
    width: 216px;
    height: auto;
}

.mobile-br {
    display: none;
}

@media (max-width: 1024px) {
    .desktop-br {
        display: none;
    }

    .enquiries-container {
        padding: 0 20px;
    }

    .newmark-column {
        margin-right: 10px;
    }

    .jll-column {
        padding-right: 10px;
    }

    .stanhope-column {
        padding-left: 15px;
    }

    .contact-person {
        font-size: 14px;
    }

    .contact-logo.newmark,
    .contact-logo.stanhope {
        width: 130px;
    }

    .contact-logo.jll {
        width: 90px;
    }
}

.enquiries-mobile-header {
    display: none;
}

@media (max-width: 600px) {
    .mobile-br {
        display: initial;
    }

    .bottom-nav {
        top: 0;
        bottom: 0;
        height: auto;
        padding: 0;
        background: transparent;
        pointer-events: none;
        transform: none;
        opacity: 1;
    }

    body.loaded .bottom-nav {
        transform: none;
        opacity: 1;
    }

    .bottom-nav .nav-left {

        position: fixed;
        bottom: 0;
        left: 0;
        width: 100%;
        height: 60px;
        justify-content: center;
        align-items: center;
        pointer-events: none;
        gap: 2rem;
        background-color: transparent;
        transform: translateY(100%);
        transition: transform 1s ease-in-out;
    }

    body.loaded .bottom-nav .nav-left {

        transform: translateY(0);
    }

    .bottom-nav .nav-right {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100px;
        display: flex;
        justify-content: center;
        align-items: center;
        pointer-events: none;
        background-color: transparent;
        transform: translateY(-100%);
        transition: transform 1s ease-in-out;
    }

    body.loaded .bottom-nav .nav-right {
        transform: translateY(0);
    }

    .bottom-nav .nav-right .nav-logo {
        height: 35px;
        width: auto;
    }

    .home-content {
        left: 50%;
        top: 50%;
        bottom: auto;
        transform: translate(-50%, -50%);
        text-align: center;
        width: 96%;
    }

    .pinch-zoom-icon {
        display: none;
    }

    body.loaded .page-section.active .home-content {
        transform: translate(-50%, -50%);
    }

    .home-content h1 {
        font-size: 44px;
        line-height: 1.2;
    }

    .home-content p {
        font-size: 16px;
    }

    /* 3. Gallery Section */
    #gallery {
        background-color: var(--bg-enquiries);
        /* Fix background color */
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        padding-top: 100px;
        padding-bottom: 80px;
    }

    .gallery-container {
        position: relative;
        height: auto;
        flex: 1;
        max-height: calc(100vh - 140px - 100px);
        max-height: calc(100dvh - 140px - 100px);
        width: 100%;
        overflow: hidden;
    }

    .gallery-image {
        background-size: contain;
        background-repeat: no-repeat;
    }

    .pinch-zoom-icon {
        display: block;
        position: absolute;
        top: 20px;
        right: 20px;
        width: 40px;
        height: 40px;
        z-index: 20;
        pointer-events: auto;
        opacity: 0.8;
    }

    .gallery-overlay {
        position: relative;
        top: auto;
        left: auto;
        right: auto;
        bottom: auto;
        height: auto;
        min-height: 80px;
        width: 100%;
        display: flex;
        justify-content: center;
        align-items: center;
        padding: 0;
        margin-top: 0;
        background: transparent;
    }

    .gallery-controls {
        position: absolute;
        top: 50%;
        left: 0;
        width: 100%;
        transform: translateY(-50%);
        display: flex;
        justify-content: space-between;
        padding: 0 20px;
        box-sizing: border-box;
        pointer-events: none;
    }

    #gallery-caption {
        color: #1A2E4D !important;

        position: relative;
        top: auto;
        bottom: auto;
        left: auto;
        transform: none;
        max-width: 60%;
        text-align: center;
        font-size: 16px;
        padding: 0;
        margin: 0;
    }

    .nav-btn {
        width: 40px;
        height: 40px;
        border: 2px solid white;
        border-radius: 50%;
        z-index: 2;
    }

    #enquiries {
        background-color: var(--bg-enquiries);
        flex-direction: column;
        justify-content: flex-start;
        padding-top: 100px;
        overflow-y: auto;
    }

    .enquiries-mobile-header {
        display: none;
        text-align: center;
        width: 85%;
        margin: 20px auto 30px;
    }

    .enquiries-mobile-header h2 {
        font-size: 36px;
        font-weight: 300;
        margin-bottom: 20px;
        color: var(--text-color);
    }

    .enquiries-mobile-header hr {
        border: none;
        border-top: 1px solid white;
        width: 100%;
        margin: 0 auto;
    }

    .enquiries-container {
        padding: 10px 0 0;
        display: flex;
        flex-wrap: wrap;
        flex-direction: row;
        align-items: flex-start;
        align-content: flex-start;
        height: auto;
        overflow-y: visible;
        gap: 28px 0;
        justify-content: center;
        margin-top: 0;
    }

    .contact-column {
        gap: 3vh;
    }

    .logo-wrapper {
        height: 3vh;
    }

    .stanhope-column {
        width: 100%;
        text-align: center;
        margin-bottom: 10px;
        border: none;
        padding: 0;
    }

    .stanhope-column::before {
        display: none;
    }

    .stanhope-intro {
        text-align: center;
        margin-bottom: 10px;
        font-size: 14px;
        font-weight: 600;
    }

    .stanhope-column .logo-wrapper {
        margin: 1vh 0 70px;
        text-align: center;
        align-items: center;
        display: flex;
        flex-direction: column;
    }

    .newmark-column,
    .jll-column {
        width: 50%;
        margin: 0;
        text-align: center;
        padding: 0 2px;
    }

    .jll-column {
        border-left: none;
    }

    .contact-person {
        font-size: 14px;
        line-height: 20px;
    }

    .contact-person strong {
        font-size: 15px;
    }

    .contact-logo {
        height: 20px;
        margin-bottom: 0;
        object-position: center;
        margin-left: auto;
        margin-right: auto;
    }

    .contact-logo.jll {
        height: 30px;
    }

    .stanhope-column .contact-logo {
        height: 30px;
    }

    .logo-wrapper {
        align-items: center;
        justify-content: center;
        margin: 1.5vh 0 0;
    }

    #terms {
        background-color: var(--bg-enquiries);
        overflow-y: auto;
    }

    .terms-container {
        padding: 100px 5% 100px;
        height: auto;
    }

    .terms-title {
        text-align: center;
        font-size: 40px;
        margin-bottom: 40px;
    }

    .terms-content-area {
        display: flex;
        flex-direction: column;
        gap: 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.7);
    }

    .terms-tab {
        width: 100%;
        font-size: 18px;
        justify-content: flex-start;
        gap: 8px;
        border-bottom: none;
        border-top: 1px solid rgba(255, 255, 255, 0.7);
    }

    .terms-pane {
        padding: 20px 0;
        padding-right: 0;
        overflow-y: visible;
    }

    .terms-pane h2 {
        display: none;
    }
}

.contact-logo.cheyne {
    margin-top: 25px;
    height: 38px;
}

.terms-links {
    margin-top: auto;
    padding-top: 80px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.enquiries-terms-link {
    color: var(--text-color);
    text-decoration: none;
    font-size: 13px;
    font-weight: 400;
}

.enquiries-terms-link:hover {
    opacity: 0.7;
}

@media (max-width: 900px) {
    .terms-links {
        padding-top: 40px;
        align-items: flex-start;
    }
}

.bottom-nav {
    color: #1A2E4D;
    transition: color 0.3s ease, transform 1s ease-in-out;
}

.bottom-nav.gallery-theme {
    color: #ffffff;
}

.nav-logo-link {
    color: inherit;
    display: inline-block;
}

.loading-logo {
    color: white;
}

.nav-link,
.nav-logo-link {
    pointer-events: auto;
}

@media (max-width: 600px) {
    .stanhope-column {
        border-top: 1px solid white !important;
        padding-top: 5px !important;
        margin-top: 0px !important;
        width: 85% !important;
        margin-left: auto !important;
        margin-right: auto !important;
    }

    .terms-links {
        border-top: 1px solid white;
        padding-top: 3vh !important;
        margin-top: 3vh;
        flex-direction: row;
        justify-content: center;
        flex-wrap: wrap;
        gap: 20px;
        width: 100% !important;
    }

    .stanhope-column .contact-logo.stanhope {
        height: 38px !important;
    }

    .stanhope-column .contact-logo.cheyne {
        height: 50px !important;
        margin-top: 20px !important;
    }
}

.contact-logo.cheyne {
    height: 57px !important;
    margin-top: 20px !important;
}

@media (max-width: 600px) {

    .bottom-nav.terms-theme .nav-left,
    .bottom-nav.terms-theme .nav-right {
        background-color: var(--bg-enquiries) !important;
    }
}

@media (max-width: 600px) {
    .bottom-nav.gallery-theme {
        color: #1A2E4D !important;
    }
}