@import url('https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,100..900;1,100..900&display=swap');
@import "../variables-P3LnbGY.css";

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: "Montserrat", sans-serif;
    font-weight: 400;
}
html, body {
    height: 100%;
}
body {
    background-color: var(--bg-main);
    color: var(--text-dark);
}
.main {
    min-height: calc(100% - var(--header-height));
    padding-top: var(--header-height);
}
.h1 {
    font-family: "Montserrat", sans-serif;
    font-weight: 600;
    font-size: 4rem;
    position: relative;
}
.highlighted {
    -webkit-text-stroke: 8px var(--text-dark);
    position: absolute;
    top: 0;
    left: 0;
    z-index: 0;
}
.text-transparent {
    color: transparent;
}
.relative {
    position: relative;
}
.z-10 {
    z-index: 10;
}

.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--header-height);
    background-color: var(--bg-main);
    z-index: 100;
}
.container {
    max-width: 1280px;
    width: 100%;
    margin: 0 auto;
}
.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
    padding: 0 1.5rem;
    gap: 2rem;
    text-align: center;
}

.header-nav {
    display: flex;
    gap: 2rem;
    order: 0;
}

.header-menu-panel {
    display: contents;
}

.header-menu-panel[hidden],
.header-menu-toggle[hidden] {
    display: none;
}

.nav-link.nav-link-disabled {
    color: var(--text-muted);
}

.nav-coming-soon {
    display: block;
    margin-top: 0.2rem;
    font-size: 0.65rem;
}

.nav-link {
    font-size: 14px;
    color: var(--text-dark);
    text-decoration: none;
    transition: opacity 0.2s ease;
}

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

.header-logo {
    order: 2;
    display: flex;
    text-decoration: none;
    flex-shrink: 0;
    width: 64px;
    height: 64px;
    background-color: var(--bg-info);
    border-radius: 50%;
    .logo {
        margin: auto;
        font-size: 42px;
    }
}

.header-auth {
    order: 3;
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-shrink: 0;
}

.header-user {
    max-width: 12rem;
    overflow: hidden;
    font-size: 0.85rem;
    font-weight: 600;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.header-logout {
    margin: 0;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1rem 2rem;
    font-size: 13px;
    letter-spacing: 0.3px;
    cursor: pointer;
    font-weight: 600;
    transition: opacity 0.2s cubic-bezier(.4, 0, .2, 1);
    border-radius: 9999px;
    text-decoration: none;
}

.btn:disabled {
    cursor: not-allowed;
    opacity: 0.5;
}

.btn-white {
    background-color: #fff;
    color: var(--text-dark);
    border: 1px solid var(--border-light);
    &:hover {
        border-color: var(--text-dark);
    }
}

.btn-black {
    background-color: var(--text-dark);
    color: var(--bg-main);
    border: 1px solid var(--text-dark);
    &:hover {
        opacity: 0.7;
    }
}
.full-screen-banner {
    position: relative;
    min-height: 80vh;
    display: flex;
    .banner-image {
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        width: 100%;
        height: 100%;
        object-fit: cover;
    }
    .banner-container {
        margin: auto;
        position: relative;
        padding: 1rem 2rem;
    }
    .banner-text-overlay {
        color: transparent;
        background-color: rgba(0, 0, 0, 0.2);
        border-radius: 1rem;
        position: absolute;
        top: 0;
        bottom: 0;
        left: 0;
        right: 0;
    }
    .banner-text {
        color: var(--bg-main);
        position: relative;
    }
}
.bg-light {
    background-color: var(--bg-light);
}
.dogs-section {
    padding: 5rem 0;
}
.dogs-container {
    color: var(--text-dark);
    max-width: 680px;
    width: 100%;
    margin: 0 auto;
}
.dog-card {
    padding: 1rem;
    background-color: var(--bg-card);
    border-radius: 2rem;
    width: 100%;
    display: flex;
    margin-bottom: 3rem;
}
.dog-card-main {
    display: flex;
    width: 100%;
}
.dog-thumbnail-column {
    padding: 1rem;
}
.dog-thumbnail {
    width: 164px;
    height: 164px;
    border-radius: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 58px;
    flex-shrink: 0;
    overflow: hidden;
}
.image-placeholder {
    width: 100%;
    height: 100%;
    background-image: url("../images/dogThumbnailPlaceholder-VQDPpnY.jpg");
    background-position: center;
    background-size: cover;
    filter: grayscale(1);
}

.dog-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.dog-info {
    padding: 1rem;
    margin: 1rem;
    background-color: var(--bg-main);
    border-radius: 1rem;
    flex-grow: 1;
    h1 {
        font-size: 22px;
        font-weight: 500;
        color: var(--text-dark);
        margin-bottom: 4px;
    }
}
.breed-tag {
    display: inline-block;
    font-size: 12px;
    padding: 2px 10px;
    border-radius: 9px;
    background: var(--bg-info);
    color: var(--text-info);
    margin-bottom: 4px;
}

.dogs-list-title {
    margin-bottom: 15px;
}

.dog-card-link {
    text-decoration: none;
    color: inherit;
}

.dog-card-row {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.dog-card-title {
    font-size: 22px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 4px;
}

.dog-info {
    min-width: 0;
}

.dog-info-header {
    display: flex;
    align-items: center;
    gap: 8px;
}

.dog-details {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem 1.5rem;
    margin: 1rem 0 0;
}

.dog-details div {
    min-width: 0;
}

.dog-details dt {
    color: var(--text-muted);
    font-size: 12px;
}

.dog-details dd {
    margin: 2px 0 0;
    overflow-wrap: anywhere;
}

.icon-button {
    width: 36px;
    height: 36px;
    border: 1px solid var(--border-light);
    border-radius: 8px;
    background: #fff;
    color: var(--text-info);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.button-icon {
    width: 1.25rem;
    height: 1.25rem;
    flex: 0 0 auto;
    fill: currentColor;
}

.icon-button:hover {
    background: var(--bg-info);
    border-color: var(--text-info);
}

.dog-edit-button {
    flex-shrink: 0;
}

/* Dog details page --------------------------------------------------------- */

.dog-detail-message {
    padding: 3rem 1.5rem;
}

.dog-profile {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
    width: 100%;
}

.dog-profile-media {
    aspect-ratio: 1;
    min-width: 0;
    overflow: hidden;
    background-color: var(--bg-card);
}

.dog-profile-media-element {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.dog-profile-media-placeholder {
    filter: grayscale(1);
}

.dog-profile-content {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
    padding: clamp(2rem, 5vw, 5rem);
    background-color: var(--bg-light);
}

.birthday-celebration {
    position: relative;
    z-index: 1;
}

.birthday-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: clamp(1.5rem, 3vw, 2.5rem);
    padding: 1rem 1.25rem;
    overflow: hidden;
    border: 1px solid rgba(255, 183, 3, 0.42);
    border-radius: 1.25rem;
    background: linear-gradient(120deg, #fff3bf, #ffe8cc 45%, #e7f5ff);
    box-shadow: 0 14px 35px rgba(190, 120, 20, 0.12);
    animation: birthday-card-arrive 700ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.birthday-card-icons {
    flex: 0 0 auto;
    font-size: clamp(1.5rem, 3vw, 2.2rem);
    letter-spacing: 0.15em;
    white-space: nowrap;
}

.birthday-card-kicker {
    margin-bottom: 0.2rem;
    color: #8a4b08;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.birthday-card-title {
    font-size: clamp(1.15rem, 2vw, 1.6rem);
    font-weight: 700;
    line-height: 1.15;
    overflow-wrap: anywhere;
}

.birthday-confetti {
    position: fixed;
    z-index: 90;
    inset: var(--header-height) 0 0;
    overflow: hidden;
    pointer-events: none;
}

.birthday-confetti-piece {
    position: absolute;
    top: -2rem;
    left: var(--birthday-left);
    width: 0.65rem;
    height: 1rem;
    border-radius: 0.15rem;
    background: var(--birthday-color);
    opacity: 0.9;
    animation: birthday-confetti-fall var(--birthday-duration) linear var(--birthday-delay) 3 both;
    will-change: transform;
}

.birthday-confetti-piece:nth-child(3n) {
    width: 0.8rem;
    height: 0.8rem;
    border-radius: 50%;
}

.birthday-confetti-piece:nth-child(4n) {
    width: 0.45rem;
    height: 1.2rem;
}

@keyframes birthday-card-arrive {
    from {
        opacity: 0;
        transform: translateY(-0.75rem) scale(0.96);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes birthday-confetti-fall {
    from {
        transform: translate3d(0, -10vh, 0) rotate(0deg);
    }

    to {
        transform: translate3d(var(--birthday-drift), 110vh, 0) rotate(var(--birthday-rotation));
    }
}

.dog-profile-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: clamp(2rem, 4vw, 4rem);
}

.dog-profile-heading h1 {
    min-width: 0;
    font-size: clamp(2.5rem, 5vw, 5rem);
    font-weight: 600;
    line-height: 1;
    overflow-wrap: anywhere;
}

.dog-profile-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-shrink: 0;
}

.action-icon-button {
    width: 3rem;
    height: 3rem;
    padding: 0;
}

.dog-profile-cards {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(1rem, 2vw, 2rem);
}

.dog-profile-card {
    padding: clamp(1.5rem, 2.5vw, 2.5rem);
    background-color: var(--bg-main);
    border-radius: 1.5rem;
}

.dog-profile-field + .dog-profile-field {
    margin-top: 1.5rem;
}

.dog-profile-field dt {
    margin-bottom: 0.35rem;
    color: var(--text-muted);
    font-size: 0.75rem;
}

.dog-profile-field dd {
    font-size: clamp(1rem, 1.5vw, 1.25rem);
    font-weight: 500;
    overflow-wrap: anywhere;
}

.dog-detail-content {
    padding: 2rem 1.5rem 0;
}

/* Dog media library ------------------------------------------------------- */

.dog-media-library {
    padding: 1.5rem;
    border-radius: 1.5rem;
    background: var(--bg-light);
}

.dog-media-library-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1.5rem;
}

.dog-media-library-heading p,
.dog-media-help,
.dog-media-status,
.dog-media-meta {
    color: var(--text-muted);
    font-size: 0.82rem;
}

.dog-media-library-heading p {
    margin-top: 0.4rem;
}

.media-upload-control {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-width: 0;
}

.media-upload-control input {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
}

.media-upload-button {
    min-height: 44px;
    padding: 0.7rem 1rem;
    border-radius: 0.75rem;
    white-space: nowrap;
}

.media-upload-control:focus-within .media-upload-button,
.media-upload-control:focus-within .treatment-photo-action {
    outline: 3px solid var(--text-info);
    outline-offset: 3px;
}

.media-upload-control:has(input:disabled) .media-upload-button,
.media-upload-control:has(input:disabled) .treatment-photo-action {
    cursor: not-allowed;
    opacity: 0.5;
}

.dog-media-help {
    margin-top: 0.75rem;
}

.dog-media-status {
    min-height: 2rem;
    padding-top: 0.6rem;
}

.dog-media-error {
    color: var(--error-red);
}

.dog-media-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1rem;
}

.dog-media-card {
    min-width: 0;
    overflow: hidden;
    border: 1px solid var(--border-light);
    border-radius: 1rem;
    background: var(--bg-main);
    transition: opacity 0.2s ease;
}

.dog-media-card.is-pending {
    opacity: 0.55;
}

.dog-media-preview {
    position: relative;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: var(--bg-card);
}

.dog-media-preview img,
.dog-media-preview video {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.dog-media-badges {
    position: absolute;
    top: 0.65rem;
    left: 0.65rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
}

.dog-media-badge {
    padding: 0.3rem 0.55rem;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.78);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 600;
}

.dog-media-card-content {
    padding: 1rem;
}

.dog-media-name {
    overflow: hidden;
    font-weight: 600;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dog-media-meta {
    margin-top: 0.3rem;
}

.dog-media-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
}

.dog-media-actions .btn {
    min-height: 44px;
    padding: 0.65rem 0.9rem;
    border-radius: 0.75rem;
    font-size: 0.72rem;
}

.dog-media-delete {
    color: var(--error-red);
}

.dog-media-empty {
    padding: 2.5rem 1rem;
    border: 1px dashed var(--border-light);
    border-radius: 1rem;
    color: var(--text-muted);
    text-align: center;
}

.btn:focus-visible,
.icon-button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 3px solid var(--text-info);
    outline-offset: 3px;
}

@media (max-width: 900px) {
    .dog-profile {
        grid-template-columns: 1fr;
    }

    .dog-profile-content {
        justify-content: flex-start;
    }
}

@media (max-width: 560px) {
    .dog-profile-content {
        padding: 2rem 1.25rem;
    }

    .dog-profile-heading {
        margin-bottom: 2rem;
    }

    .dog-profile-cards {
        grid-template-columns: 1fr;
    }

    .birthday-card {
        align-items: flex-start;
        flex-direction: column;
    }

    .dog-media-library-heading {
        flex-direction: column;
    }

    .dog-media-upload,
    .dog-media-upload label {
        width: 100%;
    }

    .media-upload-control {
        align-items: stretch;
        flex-direction: column;
    }

    .media-upload-button {
        width: 100%;
    }
}

@media (prefers-reduced-motion: reduce) {
    .birthday-card {
        animation: none;
    }

    .birthday-confetti {
        display: none;
    }

    .dog-media-card,
    .btn {
        transition: none;
    }
}

/* Modal Styles */
.modal {
    position: fixed;
    z-index: 1000;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    opacity: 0;
    transition: opacity 0.2s ease-in-out;
    pointer-events: none;
}

.modal.modal-open {
    opacity: 1;
    pointer-events: auto;
}

.modal-content {
    background-color: #fff;
    padding: 2rem;
    border-radius: 12px;
    width: 100%;
    max-width: 500px;
    max-height: calc(100vh - 2rem);
    max-height: calc(100dvh - 2rem);
    overflow-y: auto;
    overflow-wrap: anywhere;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
}

.modal-content h2 {
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
    font-weight: 500;
}

.modal-content-dog-form {
    max-width: 760px;
}

.modal-content-treatment-form {
    max-width: 640px;
}

.dog-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 1.5rem;
}

.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 14px;
    font-weight: 500;
}

.form-group input[type="text"],
.form-group input[type="number"],
.form-group input[type="date"],
.form-group select,
.form-group textarea {
    width: 100%;
    min-width: 0;
    padding: 10px;
    border: 1px solid var(--border-light);
    border-radius: 6px;
    font-size: 14px;
}

.form-group input[type="file"] {
    font-size: 14px;
}

.modal-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 2rem;
}

.modal-error {
    margin-top: 1rem;
    color: var(--error-red);
    font-size: 14px;
}

.treatment-photo-field {
    padding-top: 0.5rem;
    border-top: 1px solid var(--border-light);
}

.treatment-photo-label {
    margin-bottom: 0.5rem;
    font-size: 14px;
    font-weight: 500;
}

.treatment-photo-preview {
    width: min(100%, 320px);
    aspect-ratio: 4 / 3;
    margin-bottom: 0.75rem;
    overflow: hidden;
    border: 1px solid var(--border-light);
    border-radius: 0.75rem;
    background: var(--bg-card);
}

.treatment-photo-preview img,
.treatment-photo-full {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.treatment-photo-help {
    margin-bottom: 0.65rem;
    color: var(--text-muted);
    font-size: 0.8rem;
}

.treatment-photo-help {
    margin-top: 0.5rem;
}

.treatment-photo-control {
    width: fit-content;
}

.form-group .treatment-photo-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    min-height: 44px;
    margin-bottom: 0;
    padding: 0;
    border-radius: 0.75rem;
}

.modal-content-treatment-photo {
    max-width: min(900px, calc(100vw - 2rem));
}

.treatment-photo-full {
    max-height: calc(100vh - 12rem);
}

@media (max-width: 640px) {
    .dog-form-grid {
        grid-template-columns: 1fr;
    }
}

/* Footer Styles */
.footer {
    background-color: #000;
    color: #fff;
    margin-top: 4rem;
}

.footer-top {
    padding: 2rem 0;
}

.footer-container {
    display: flex;
    align-items: center;
}

.footer-section-1 {
    display: flex;
    align-items: center;
    gap: 2rem;
    width: 100%;
}

.footer-logo {
    text-decoration: none;
    display: flex;
    align-items: center;
    font-size: 2.5rem;
    flex-shrink: 0;
}

.logo-inverted {
    filter: invert(1);
}

.footer-nav {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.footer-nav-link {
    color: #fff;
    text-decoration: none;
    font-size: 0.95rem;
    transition: opacity 0.3s ease;
}

.footer-nav-link:hover {
    opacity: 0.7;
}

.footer-divider {
    height: 1px;
    background-color: #666;
    margin: 0;
}

.footer-bottom {
    padding: 2rem 0;
}

.footer-links-container {
    display: flex;
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.footer-link {
    color: #fff;
    text-decoration: none;
    font-size: 0.9rem;
    transition: opacity 0.3s ease;
}

.footer-link:hover {
    opacity: 0.7;
}

@media (max-width: 768px) {
    .footer-section-1 {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
    }

    .footer-nav {
        width: 100%;
        justify-content: center;
        text-align: center;
    }

    .footer-links {
        gap: 0.75rem;
        padding-inline: 10px;
    }
}

/* Treatments Styles */
.treatments-section {
    margin-top: 2rem;
    padding: 1.5rem;
}

.h2 {
    font-size: 2em;
    font-weight: 600;
}

.treatments-heading {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.treatments-table {
    width: 100%;
    min-width: 40rem;
    border-collapse: collapse;
    font-size: 14px;
    .treatment-actions {
        text-align: center;
        .btn {
            margin: 0 10px;
        }
    }
}

.treatments-scroll {
    max-width: 100%;
    overflow-x: auto;
    padding: 0.25rem;
}

.treatments-scroll:focus-visible {
    outline: 3px solid var(--text-info);
    outline-offset: 3px;
}

.treatments-table td {
    max-width: 20rem;
    overflow-wrap: anywhere;
}

.treatments-table th {
    padding: 12px;
    text-align: left;
    font-weight: 600;
    border-bottom: 1px solid var(--border-light);
}

.treatments-table td {
    padding: 12px;
    border-bottom: 1px solid var(--border-light);
}

.treatments-table tbody tr:hover {
    background-color: rgba(0, 0, 0, 0.02);
}

.treatment-photo-column {
    width: 5rem;
    text-align: center !important;
}

.treatment-photo-button {
    width: 2.5rem;
    height: 2.5rem;
    margin: 0 !important;
}

.treatment-badge {
    display: inline-block;
    background-color: var(--bg-info);
    color: var(--text-info);
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
    margin-right: 4px;
}



.modal-content-confirm {
    text-align: center;
}

.modal-content-confirm p {
    margin-bottom: 2rem;
    color: var(--text-dark);
    font-size: 14px;
}

/* Vue apps ---------------------------------------------------------------- */

.vue-loading {
    color: var(--text-muted, #777);
    font-size: 0.88rem;
}
.btn-row {
    display: flex;
    justify-content: center;
}
.api-error {
    color: var(--error-red);
    margin: 2rem 0;
    text-align: center;
}

/* Error pages ------------------------------------------------------------ */

.main:has(.error-page) {
    min-height: 100%;
}

.error-page {
    display: grid;
    min-height: calc(100vh - var(--header-height));
    padding: clamp(2rem, 8vw, 6rem) 1.5rem;
    place-items: center;
    background:
        radial-gradient(circle at 85% 15%, var(--bg-info) 0, transparent 28rem),
        var(--bg-light);
}

.error-card {
    width: min(100%, 620px);
    padding: clamp(2rem, 6vw, 4rem);
    border-radius: 2rem;
    background: var(--bg-main);
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.08);
    text-align: center;
}

.error-code {
    margin-bottom: 0.75rem;
    color: var(--text-info);
    font-size: clamp(3rem, 10vw, 6rem);
    font-weight: 700;
    line-height: 1;
}

.error-card h1 {
    margin-bottom: 1rem;
    font-size: clamp(1.75rem, 5vw, 2.5rem);
    font-weight: 600;
}

.error-card > p:not(.error-code) {
    margin: 0 auto 2rem;
    color: var(--text-muted);
    line-height: 1.6;
}

/* Authentication pages --------------------------------------------------- */

.main:has(.auth-page) {
    min-height: 100%;
    padding-top: 0;
}

.auth-page {
    display: flex;
    min-height: 100vh;
    padding: clamp(2rem, 6vw, 5rem) 1.5rem;
    background:
        radial-gradient(circle at 15% 15%, var(--bg-info) 0, transparent 28rem),
        var(--bg-light);
}

.auth-card {
    width: min(100%, 520px);
    margin: auto;
    padding: clamp(2rem, 5vw, 3.5rem);
    border-radius: 2rem;
    background-color: var(--bg-main);
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.08);
}

.auth-heading {
    margin-bottom: 2rem;
    text-align: center;
}

.auth-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 4rem;
    height: 4rem;
    margin-bottom: 1.25rem;
    border-radius: 50%;
    background-color: var(--bg-info);
    color: var(--text-info);
}

.auth-icon-svg {
    width: 2rem;
    height: 2rem;
    fill: currentColor;
}

.auth-icon-emoji {
    font-size: 2rem;
}

.auth-eyebrow {
    margin-bottom: 0.5rem;
    color: var(--text-info);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.auth-heading h1 {
    font-size: 2rem;
    font-weight: 600;
    line-height: 1.05;
}

.auth-heading > p:last-child {
    max-width: 390px;
    margin: 1rem auto 0;
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.6;
}

.auth-field + .auth-field {
    margin-top: 1.25rem;
}

.auth-field label,
.auth-label-row a {
    font-size: 0.82rem;
    font-weight: 600;
}

.auth-field > label,
.auth-label-row {
    display: flex;
    margin-bottom: 0.55rem;
}

.auth-label-row {
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.auth-label-row a,
.auth-switch a {
    color: var(--text-info);
    text-decoration: none;
}

.auth-label-row a:hover,
.auth-switch a:hover {
    text-decoration: underline;
}

.auth-field input {
    width: 100%;
    min-height: 3.25rem;
    padding: 0.85rem 1rem;
    border: 1px solid var(--border-light);
    border-radius: 0.85rem;
    background: var(--bg-main);
    color: var(--text-dark);
    font-size: 0.9rem;
}

.auth-field input::placeholder {
    color: var(--text-muted);
}

.auth-field input[aria-invalid="true"] {
    border-color: var(--error-red);
}

.auth-errors {
    margin-bottom: 1.25rem;
    padding: 0.85rem 1rem;
    border-radius: 0.85rem;
    background: color-mix(in srgb, var(--error-red) 10%, transparent);
    color: var(--error-red);
    font-size: 0.82rem;
    line-height: 1.5;
}

.auth-field-error {
    margin-top: 0.45rem;
    color: var(--error-red);
    font-size: 0.76rem;
    line-height: 1.4;
}

.auth-check {
    display: flex;
    align-items: flex-start;
    gap: 0.65rem;
    margin-top: 1.25rem;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 0.8rem;
    line-height: 1.4;
}

.auth-check input {
    width: 1rem;
    height: 1rem;
    margin-top: 0.05rem;
    accent-color: var(--text-dark);
    flex: 0 0 auto;
}

.auth-submit {
    width: 100%;
    margin-top: 1.75rem;
    text-decoration: none;
}

.auth-switch {
    margin-top: 1.75rem;
    padding-top: 1.75rem;
    border-top: 1px solid var(--border-light);
    color: var(--text-muted);
    font-size: 0.85rem;
    text-align: center;
}

.auth-switch a {
    font-weight: 600;
}

.auth-back {
    display: inline-flex;
    margin-bottom: 1.75rem;
    color: var(--text-muted);
    font-size: 0.8rem;
    font-weight: 600;
    text-decoration: none;
}

.auth-back:hover {
    color: var(--text-dark);
}

.auth-heading-spacious {
    margin-bottom: 2.5rem;
}

.auth-notice {
    padding: 1rem 1.25rem;
    border-radius: 1rem;
    background-color: var(--bg-info);
    color: var(--text-info);
    font-size: 0.82rem;
    line-height: 1.6;
}

.auth-help {
    margin-top: 0.5rem;
    color: var(--text-muted);
    font-size: 0.75rem;
}

@media (max-width: 799px) {
    .header-container {
        gap: 0.5rem;
        padding-inline: 1rem;
    }

    .header-menu-toggle {
        flex-shrink: 0;
        min-width: 44px;
        min-height: 44px;
        padding: 10px;
        border: 0;
        background: transparent;
    }

    .header-menu-panel {
        display: flex;
        position: absolute;
        top: calc(var(--header-height) - 1px);
        left: 0;
        right: 0;
        flex-direction: column;
        gap: 1rem;
        padding: 1rem;
        background-color: var(--bg-light);
        box-shadow: 0 8px 12px rgb(0 0 0 / 10%);
        max-height: calc(100dvh - var(--header-height));
        overflow-y: auto;
    }

    .header-logo {
        margin-left: auto;
    }

    .header-nav {
        flex-direction: column;
        gap: 1rem;
    }

    .header-nav .nav-link {
        min-height: 44px;
        padding: 0.75rem;
    }

    .header-auth {
        order: 1;
        justify-content: center;
        flex-shrink: 1;
        min-width: 0;
        gap: 1rem;
        margin: 1rem 0;
    }

    .header-user {
        min-width: 0;
    }

    .header-logout {
        flex-shrink: 0;
    }

    .header-auth .btn {
        min-height: 44px;
        padding: 0.75rem 1rem;
    }
}

@media (max-width: 480px) {
    .dog-card-main {
        flex-direction: column;
        min-width: 0;
    }

    .dog-thumbnail-column {
        padding: 0;
    }

    .dog-thumbnail {
        width: 100%;
    }

    .dog-info {
        margin: 1rem 0 0;
        overflow-wrap: anywhere;
    }

    .treatment-photo-button {
        width: 44px;
        height: 44px;
    }

    .modal-content {
        padding: 1.25rem;
    }

    .modal-actions .btn {
        flex: 1 1 auto;
        padding: 0.85rem 1rem;
    }

    .auth-page {
        padding: 1rem;
    }

    .auth-card {
        padding: 1.5rem;
        border-radius: 1.5rem;
    }

    .header-logo {
        width: 52px;
        height: 52px;
    }

    .header-logo .logo {
        font-size: 34px;
    }
}
