/* ============================================
   Tablet Responsive Styles (max-width: 1040px)
   ============================================ */

@media (max-width: 1040px) {
    .container {
        padding: 0 2rem 0 2rem;
    }

    .logo h1 {
        font-size: 1.5rem;
    }

    .hamburger {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        top: 0px;
        right: -100%;
        width: 30%;
        height: 100vh;
        background-image: linear-gradient(to bottom, transparent 4rem, var(--primary-yellow) 4rem);
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        align-items: stretch;
        gap: initial;
        transition: right 0.3s ease;
        z-index: 999;
        padding: 5rem 0 2rem 0;
    }

    .nav-menu.active {
        right: 0;
    }

    .nav-menu ul {
        flex-direction: column;
        justify-content: flex-start;
        align-items: stretch;
        gap: initial;
        list-style: none;
        margin: 0;
        padding: 0;
    }

    .nav-menu li {
        border-bottom: 1px solid var(--border-blown);
    }

    .nav-menu li:first-child {
        border-top: 1px solid var(--border-blown);
    }

    .nav-menu a {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 1rem 2rem;
        font-size: 1.1rem;
        font-weight: 400;
        color: var(--text-brown);
    }

    .nav-menu a:hover {
        background-color: rgba(255, 255, 255, 0.1);
    }

    .nav-arrow {
        display: block;
        width: 12px;
        height: auto;
        flex-shrink: 0;
    }

    .nav-menu .nav-contact {
        display: block;
        margin: 0 2rem;
    }

    .contact-cta-button {
        display: inline-block;
        border: 2px solid var(--accent-orange);
        border-radius: 50px;
        background-color: transparent;
        color: var(--accent-orange);
        text-decoration: none;
        font-size: 0.95rem!important;
        font-weight: 600;
        transition: all 0.3s ease;
        padding: 1rem!important;
    }

    .contact-cta-button:hover {
        background-color: var(--accent-orange);
        color: var(--text-white);
    }
    
    /* Hero text sizes - scale with viewport */
    .text-small {
        font-size: clamp(1rem, 2vw, 1.5rem);
    }

    .text-large {
        font-size: clamp(2rem, 4vw, 3rem);
    }

    .text-medium {
        font-size: clamp(1.3rem, 2.5vw, 2rem);
    }

    .hero-main-image {
        max-width: 90%;
    }

    .hero-title-vertical {
        gap: clamp(0.8rem, 1.5vw, 1.5rem);
    }

    .hero-text-column.column-1 {
        padding-top: 0;
    }

    .hero-text-column.column-2 {
        padding-top: clamp(1rem, 3vw, 3rem);
    }

    .hero-text-column.column-3 {
        padding-top: clamp(8rem, 20vw, 20rem);
    }

    .hero-text-tablet {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 1.5rem;
        text-align: center;
        padding: 0 1rem;
    }

    /* Concerns section - switch to mobile layout */
    .concerns .container {
        background-image: url('../../image/concerns/sp-background.png');
        background-size: 100% 900px;
        background-position: center top;
        background-repeat: no-repeat;
        height: 900px;
    }
    .concerns-content{
        height: 850px;
    }
    .speech-desktop {
        display: none;
    }

    .speech-mobile {
        display: flex;
    }
    /* Position speech bubbles for mobile layout */

    .speech-mobile.speech-1 {
        background-image: url('../../image/concerns/sp-speech1.png');
        top: 10px;
        left: 50%;
    }

    .speech-mobile.speech-2 {
        background-image: url('../../image/concerns/sp-speech2.png');
        top: 90px;
        left: calc(50% - 250px);
    }

    .speech-mobile.speech-3 {
        background-image: url('../../image/concerns/sp-speech3.png');
        top: 210px;
        left: 50%;
    }

    .speech-mobile.speech-4 {
        background-image: url('../../image/concerns/sp-speech4.png');
        top: 290px;
        left: calc(50% - 250px);
    }

    .speech-mobile.speech-5 {
        background-image: url('../../image/concerns/sp-speech5.png');
        top: 410px;
        left: 50%;
    }

    .speech-mobile.speech-1 p {
        top: -15px;
        left: 0px;
    }

    .speech-mobile.speech-2 p {
        top: -20px;
        left: 5px;
    }

    .speech-mobile.speech-3 p {
        top: -20px;
        left: 0px;
    }

    .speech-mobile.speech-4 p {
        top: -20px;
        left: 5px;
    }

    .speech-mobile.speech-5 p {
        top: -25px;
        left: 0px;
    }

    .human-1 {
        bottom: 0px;
        left: calc(50% - 120px);
    }

    .human-2 {
        bottom: 10px;
        left: 50%;
    }

    .human-3 {
        bottom: 0px;
        left: calc(50% + 125px);
    }

    .footer-title {
        font-size: 1.4rem;
    }
    
    .footer-links {
        grid-template-columns: 1fr;
        gap: 0.8rem;
        text-align: center;
    }

    .footer-column ul {
        align-items: center;
    }

    .footer-column a {
        padding: 0.5rem 0;
        display: block;
    }

    .footer-column a:hover {
        background-color: rgba(255, 255, 255, 0.1);
    }
    
    /* Floating Contact Button */
    .floating-contact-button-desktop {
        display: none;
    }

    .floating-contact-button-mobile {
        display: flex;
        justify-content: center;
        margin-top: 2rem;
    }

}
