html {
    max-width: 100%;
    overflow-x: hidden;
    text-size-adjust: 100%;
}

body {
    max-width: 100%;
    overflow-x: hidden;
}

*,
*::before,
*::after {
    min-width: 0;
}

img,
video,
iframe,
canvas,
svg {
    max-width: 100%;
}

img,
video {
    height: auto;
}

input,
select,
textarea,
button,
.btn,
a {
    max-width: 100%;
}

input,
select,
textarea {
    min-width: 0;
}

h1,
h2,
h3,
.brand,
.auth-title,
.admin-title,
.name,
.value,
.lead,
.muted,
.caption,
.services,
.service,
.badge,
.detail,
.booking,
.queue-item,
td,
th,
code {
    overflow-wrap: anywhere;
}

table {
    max-width: 100%;
}

.page,
.container,
.admin-container,
.auth-wrapper,
form,
.panel,
.card,
.stat,
.glass,
.hero-main,
.side,
.body,
.top,
.topbar,
.panel-head,
.booking-top,
.queue-item {
    min-width: 0;
}

.photo,
.portrait,
.preview img,
.preview video,
.media-card img,
.media-card video,
.gallery-card img,
.gallery-card video {
    object-fit: cover;
}

@media (max-width: 760px) {
    body {
        overflow-x: hidden;
    }

    .page,
    .container,
    .admin-container {
        width: min(100% - 24px, 1200px) !important;
    }

    body[style],
    body {
        min-width: 0;
    }

    .top,
    .topbar,
    .panel-head,
    .booking-top {
        align-items: stretch !important;
        flex-direction: column !important;
    }

    .actions,
    .links,
    .hero-actions,
    .legal-links,
    nav {
        max-width: 100%;
    }

    .actions,
    .links,
    .hero-actions,
    .legal-links,
    .inline,
    .card-actions {
        display: grid !important;
        grid-template-columns: 1fr !important;
        width: 100% !important;
    }

    .btn,
    button,
    .admin-link,
    .logout,
    nav a {
        width: 100%;
    }

    .hero,
    .grid,
    .stats,
    .workflow,
    .split,
    .cards,
    .cities,
    .trust-strip,
    .assurance-grid,
    .quick-grid,
    .booking-strip,
    .service-picker {
        grid-template-columns: 1fr !important;
    }

    .full,
    textarea,
    .service-picker,
    .gallery-card:first-child {
        grid-column: 1 / -1 !important;
    }

    .photo-wrap,
    .visual,
    .portrait {
        min-height: 300px !important;
    }

    .photo,
    .portrait {
        width: 100%;
        height: auto;
        aspect-ratio: 4 / 5;
        display: block;
    }

    .gallery {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }

    .gallery-card img,
    .gallery-card video,
    .media-card img,
    .media-card video {
        height: auto !important;
    }

    .detail,
    .booking,
    .queue-item {
        align-items: stretch !important;
        flex-direction: column !important;
    }

    td,
    th {
        max-width: 100%;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: clamp(2rem, 12vw, 2.75rem) !important;
        line-height: 1.05 !important;
    }

    h2 {
        font-size: clamp(1.45rem, 9vw, 2rem) !important;
        line-height: 1.12 !important;
    }

    .page,
    .container,
    .admin-container {
        width: min(100% - 20px, 1200px) !important;
    }

    .panel,
    .card,
    .stat,
    .glass,
    .intro,
    .auth-wrapper,
    form {
        padding-left: min(18px, 5vw) !important;
        padding-right: min(18px, 5vw) !important;
    }

    .gallery {
        grid-template-columns: 1fr !important;
    }

    .badges,
    .services {
        gap: 7px !important;
    }

    .badge,
    .service {
        max-width: 100%;
    }

    .photo-caption {
        left: 10px !important;
        right: 10px !important;
        bottom: 10px !important;
    }
}
