/* =========================================================
   Path & Paws - Main Stylesheet
   Clean responsive stylesheet
   ========================================================= */

/* =========================================================
   RESET / BASE
   ========================================================= */

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

html {
    width: 100%;
    min-height: 100%;
    overflow-x: hidden;
}

body {
    margin: 0;
    width: 100%;
    min-height: 100%;
    font-family: "Nunito Sans", sans-serif;
    color: #0F2233;
    background: #f5f5f5;
    overflow-x: hidden;
}

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

a {
    color: inherit;
}

h1,
h2,
h3,
h4,
p {
    margin-top: 0;
}

h1,
h2,
h3 {
    line-height: 1.15;
}

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

.nav {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;

    display: flex;
    align-items: center;

    width: 100%;
    padding: 8px 30px;
    margin: 0;

    gap: 30px;
}

.nav .navbar-brand {
    display: flex;
    align-items: center;
    flex-shrink: 0;

    padding: 0;
    margin: 0;

    line-height: 1;
}

.nav .navbar-brand img {
    display: block;
    width: 175px;
    height: auto;
}

.nav nav {
    display: flex;
    align-items: center;
    justify-content: center;

    flex: 1;
    gap: 28px;

    margin: 0;
    padding: 0;
}

.nav nav a {
    display: inline-block;

    color: #ffffff;
    text-decoration: none;
    font-weight: 600;
    white-space: nowrap;

    padding: 8px 2px;

    transition:
        opacity 0.2s ease,
        transform 0.2s ease;
}

.nav nav a:hover {
    opacity: 0.75;
}

.nav .btn-primary {
    flex-shrink: 0;
    white-space: nowrap;
}

/* =========================================================
   BUTTONS
   ========================================================= */

.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-height: 44px;
    padding: 12px 20px;

    background: linear-gradient(135deg, #f4f1ea, #c2a878);
    color: #0F2233;

    border-radius: 6px;
    border: 0;

    text-decoration: none;
    font-family: inherit;
    font-weight: 600;
    line-height: 1.2;

    cursor: pointer;

    transition:
        transform 0.25s ease,
        box-shadow 0.25s ease;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.btn-primary:focus-visible,
.nav nav a:focus-visible {
    outline: 3px solid rgba(244, 241, 234, 0.9);
    outline-offset: 3px;
}

/* =========================================================
   HERO SECTIONS
   ========================================================= */

.hero,
.herohome,
.page-hero {
    position: relative;

    width: 100%;
    min-height: 100svh;

    display: flex;
    align-items: center;
    justify-content: center;

    overflow: hidden;
}

.hero {
    background: url("../assets/page-bg.png") center center / cover no-repeat;
    padding: 120px 20px 60px;
}

.herohome {
    background: url("../assets/hero.png") center center / cover no-repeat;
    padding: 120px 20px 60px;
}

.page-hero {
    background: url("../assets/page-bg.png") center center / cover no-repeat;
    color: #0F2233;
    padding: 120px 20px 60px;
}

.overlay {
    position: absolute;
    inset: 0;

    width: 100%;
    height: 100%;

    background: rgba(0, 0, 0, 0.5);
}

.hero-content {
    position: relative;
    z-index: 2;

    width: 100%;
    max-width: 900px;

    margin: 0 auto;

    text-align: center;
}

.hero-content h1 {
    font-size: clamp(2.1rem, 6vw, 4rem);
}

.hero-content p {
    font-size: clamp(1rem, 2.5vw, 1.25rem);
    line-height: 1.6;
}

/* =========================================================
   SERVICE BOXES
   ========================================================= */

.service-boxes {
    position: relative;
    z-index: 2;

    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));

    width: min(96%, 1350px);
    margin: 210px auto 0;

    gap: 30px;
}

.service-boxes .box {
    width: 100%;
    min-width: 0;
}

/* =========================================================
   CONTENT BOX
   ========================================================= */

.box {
    background: rgba(244, 241, 234, 0.92);
    color: #0F2233;

    padding: 20px;

    border-radius: 8px;

    text-decoration: none;

    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

/* =========================================================
   GENERAL PAGE
   ========================================================= */

.page {
    width: 100%;
    padding: 60px 20px;

    color: #000000;
    background: #f5f5f5;
}

.page-content {
    position: relative;
    z-index: 2;

    width: min(100%, 900px);
    margin: 0 auto;
}

.page-content .box {
    width: 100%;
}

.cta-section {
    margin-top: 40px;
}

/* =========================================================
   CONTACT FORM
   ========================================================= */

.contact-form {
    width: 100%;
    max-width: 700px;
    margin: 0 auto;
}

.form-row {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
}

.form-row.full {
    flex-direction: column;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    min-width: 0;

    flex: 1;

    padding: 12px;

    border: 1px solid #ccc;
    border-radius: 4px;

    background: #ffffff;
    color: #0F2233;

    font-family: inherit;
    font-size: 16px;
    line-height: 1.4;
}

.contact-form textarea {
    min-height: 120px;
    resize: vertical;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: 2px solid #c2a878;
    outline-offset: 1px;
}

/* =========================================================
   DOG WALKING PAGE
   ========================================================= */

.dog-walking-page {
    color: #071117;
}

.dog-walking-page section {
    margin-bottom: 3rem;
}

.dog-walking-page .lead {
    font-size: clamp(1.05rem, 2.5vw, 1.25rem);
    line-height: 1.7;
}

.dog-walking-page .highlight {
    font-size: clamp(1.05rem, 2.5vw, 1.25rem);
}

.dog-walking-page .cta {
    text-align: center;
}

.dog-walking-page .cta-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-height: 44px;
    padding: 12px 24px;
}

.wedding-day-care ul {
    text-align: left;
}

.suitable-for ul {
    width: fit-content;
    max-width: 90%;

    margin: 1.5rem auto;
    padding-left: 1.5rem;

    text-align: left;
}

.suitable-for li {
    margin-bottom: 0.4rem;

    text-align: left;
    line-height: 1.5;
}

/* =========================================================
   TABLET
   ========================================================= */

@media (max-width: 900px) {

    .nav {
        padding: 12px 20px;
        gap: 12px 20px;
    }

    .nav .navbar-brand img {
        width: 155px;
    }

    .nav nav {
        gap: 10px 18px;
    }

    .nav nav a {
        padding: 8px 0;
    }

    .nav .btn-primary {
        padding: 10px 16px;
    }

    .service-boxes {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        width: min(92%, 700px);
        gap: 20px;
    }
}

/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 700px) {

    /* Navigation:
       Keep the existing navigation markup, but make it stack
       cleanly rather than allowing awkward wrapping. */

    .nav {
        /* Let the mobile navigation occupy its own space.
           This prevents the CTA button from sitting on top
           of the hero content. */
        position: relative;

        display: flex;
        flex-direction: column;
        align-items: center;

        width: 100%;

        padding: 12px 16px 16px;

        gap: 10px;

        background: transparent;
    }

    .nav .navbar-brand {
        width: 100%;
        justify-content: center;
    }

    .nav .navbar-brand img {
        width: 145px;
    }

    .nav nav {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;

        width: 100%;

        gap: 4px 14px;
    }

    .nav nav a {
        font-size: 0.95rem;
        padding: 6px 2px;
        color: #0F2233;
    }

    .nav .btn-primary {
        width: auto;
        max-width: 100%;

        margin-top: 2px;

        padding: 10px 16px;
        font-size: 0.95rem;
    }

    /* Hero */

    /* Use ONE fixed page-level background image on mobile.
       A fixed pseudo-element is used rather than
       background-attachment: fixed because iOS Safari does not
       reliably honour background-attachment: fixed on body. */
    body {
        position: relative;
        background: #f4f1ea;
        isolation: isolate;
    }

    body::before {
        content: "";
        position: fixed;
        inset: 0;
        z-index: -1;

        background-image: url("../assets/page-bg.png");
        background-position: center center;
        background-size: cover;
        background-repeat: no-repeat;

        pointer-events: none;
    }

    /* Mobile heroes are transparent so they reveal the single
       page-level background image behind them. */
    .hero,
    .herohome,
    .page-hero {
        /*
         * Navigation is part of normal document flow, so keep
         * the gap before the hero content deliberately small.
         */
        min-height: calc(100svh - 190px);

        padding: 8px 16px 50px;

        background-image: none;
        background-color: transparent;

        color: #0F2233;

        align-items: flex-start;
    }

    .herohome {
        min-height: calc(100svh - 190px);
        padding-top: 8px;
    }

    .hero .overlay,
    .herohome .overlay,
    .page-hero .overlay {
        display: none;
    }

    /* The mobile navigation is now part of the normal page flow,
       so hero content starts below it rather than underneath it. */
    .hero-content {
        width: 100%;
        max-width: 900px;
    }

    .hero-content {
        max-width: 100%;
    }

    .hero-content h1 {
        margin-bottom: 18px;
        font-size: clamp(2rem, 10vw, 3rem);
    }

    .hero-content p {
        font-size: 1rem;
        line-height: 1.55;
    }

    /* Services */

    .service-boxes {
        grid-template-columns: 1fr;

        width: calc(100% - 32px);

        gap: 15px;

        margin-top: 8px;
    }

    .service-boxes .box {
        padding: 18px;
    }

    /* General page */

    .page {
        padding: 40px 16px;
    }

    .page-content {
        width: 100%;
    }

    /* Typography */

    .page h1 {
        font-size: clamp(2rem, 9vw, 2.8rem);
    }

    .page h2 {
        font-size: clamp(1.5rem, 7vw, 2.2rem);
    }

    .page h3 {
        font-size: clamp(1.2rem, 5vw, 1.5rem);
    }

    .page p,
    .page li {
        line-height: 1.6;
    }

    /* Contact form */

    .form-row {
        flex-direction: column;
        gap: 12px;
    }

    .contact-form input,
    .contact-form textarea {
        width: 100%;
        font-size: 16px;
    }

    /* Lists */

    .suitable-for ul {
        width: 100%;
        max-width: 100%;
        padding-left: 1.25rem;
    }

    /* Buttons */

    .btn-primary,
    .dog-walking-page .cta-button {
        min-height: 46px;
    }

    /* Prevent very long content from creating horizontal scrolling */

    .box,
    .page-content,
    .contact-form {
        overflow-wrap: anywhere;
    }
}

/* =========================================================
   SMALL PHONES
   ========================================================= */

@media (max-width: 400px) {

    .nav {
        padding-left: 12px;
        padding-right: 12px;
    }

    .nav .navbar-brand img {
        width: 130px;
    }

    .nav nav {
        gap: 2px 10px;
    }

    .nav nav a {
        font-size: 0.9rem;
        color: #0F2233;
    }

    .nav .btn-primary {
        font-size: 0.9rem;
        padding: 9px 13px;
    }

    .hero,
    .herohome,
    .page-hero {
        padding-left: 12px;
        padding-right: 12px;
    }

    .service-boxes {
        width: 100%;
    }

    .box {
        padding: 16px;
    }
}

/* =========================================================
   REDUCED MOTION
   ========================================================= */

@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }
}
