.cms-profile-grid {
    display: grid;
    grid-template-columns: minmax(260px, 340px) minmax(0, 1fr);
    gap: 24px;
}

.cms-profile-card,
.cms-form-panel {
    min-width: 0;
    padding: clamp(22px, 3vw, 30px);
    border: 1px solid rgba(255, 255, 255, 0.075);
    border-radius: 20px;
    background:
        linear-gradient(
            180deg,
            rgba(20, 29, 49, 0.98),
            rgba(16, 23, 40, 0.98)
        );
    box-shadow: 0 18px 48px rgba(0, 0, 0, 0.18);
}

.cms-profile-card {
    align-self: start;
}

.cms-profile-avatar-wrap {
    width: 118px;
    height: 118px;
    margin: 0 auto 22px;
    padding: 5px;
    border-radius: 50%;
    background:
        linear-gradient(
            135deg,
            #5d84ff,
            #315cda
        );
    box-shadow: 0 16px 34px rgba(79, 124, 255, 0.25);
}

.cms-profile-avatar {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border: 4px solid #11182b;
    border-radius: 50%;
}

.cms-profile-summary {
    text-align: center;
}

.cms-profile-summary h2 {
    margin: 8px 0 8px;
    color: #ffffff;
    font-size: 1.5rem;
}

.cms-profile-summary p {
    margin: 0;
    color: #8f9bb2;
    font-size: 0.88rem;
    line-height: 1.6;
}

.cms-profile-meta {
    margin: 24px 0;
    display: grid;
}

.cms-profile-meta div {
    padding: 14px 0;
    display: grid;
    gap: 5px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.065);
}

.cms-profile-meta div:last-child {
    border-bottom: 0;
}

.cms-profile-meta span {
    color: #7f8da8;
    font-size: 0.76rem;
    font-weight: 700;
}

.cms-profile-meta strong {
    overflow-wrap: anywhere;
    color: #ffffff;
    font-size: 0.88rem;
}

.cms-form {
    display: grid;
    gap: 20px;
}

.cms-form-group {
    display: grid;
    gap: 9px;
}

.cms-form-group label {
    color: #edf2ff;
    font-size: 0.86rem;
    font-weight: 800;
}

.cms-form-group input {
    width: 100%;
    min-height: 50px;
    padding: 12px 14px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    outline: none;
    color: #ffffff;
    background: rgba(8, 13, 25, 0.72);
    font: inherit;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        background 0.2s ease;
}

.cms-form-group input:focus {
    border-color: #5d84ff;
    background: rgba(8, 13, 25, 0.9);
    box-shadow: 0 0 0 4px rgba(79, 124, 255, 0.14);
}

.cms-form-group input:disabled {
    color: #7f8da8;
    cursor: not-allowed;
    background: rgba(255, 255, 255, 0.035);
}

.cms-form-group small {
    color: #7f8da8;
    font-size: 0.75rem;
    line-height: 1.5;
}

.cms-form-actions {
    margin-top: 4px;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.cms-secondary-button {
    min-height: 48px;
    padding: 0 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, 0.09);
    border-radius: 13px;
    color: #c7d0e2;
    background: rgba(255, 255, 255, 0.035);
    text-decoration: none;
    font-size: 0.88rem;
    font-weight: 800;
    transition:
        background 0.2s ease,
        color 0.2s ease,
        border-color 0.2s ease;
}

.cms-secondary-button:hover {
    color: #ffffff;
    border-color: rgba(79, 124, 255, 0.28);
    background: rgba(79, 124, 255, 0.08);
}

.cms-alert {
    margin-bottom: 20px;
    padding: 15px 16px;
    border-radius: 13px;
}

.cms-alert strong {
    display: block;
    margin-bottom: 7px;
}

.cms-alert p {
    margin: 0;
    font-size: 0.84rem;
    line-height: 1.55;
}

.cms-alert p + p {
    margin-top: 5px;
}

.cms-alert-error {
    color: #fecaca;
    border: 1px solid rgba(248, 113, 113, 0.28);
    background: rgba(127, 29, 29, 0.24);
}

.cms-alert-success {
    color: #bbf7d0;
    border: 1px solid rgba(74, 222, 128, 0.24);
    background: rgba(20, 83, 45, 0.25);
}

/* Pagina schimbare avatar */

.dashboard-grid-two {
    display: grid;
    grid-template-columns: minmax(260px, 340px) minmax(0, 1fr);
    gap: 24px;
}

.avatar-current-wrapper {
    display: grid;
    gap: 22px;
    justify-items: center;
    padding: 10px 0 4px;
    text-align: center;
}

.avatar-current-frame {
    width: clamp(145px, 18vw, 190px);
    aspect-ratio: 1;
    padding: 6px;
    overflow: hidden;
    border-radius: 50%;
    background:
        linear-gradient(
            135deg,
            #5d84ff,
            #315cda
        );
    box-shadow:
        0 20px 45px rgba(49, 92, 218, 0.28),
        0 0 0 8px rgba(79, 124, 255, 0.06);
}

.avatar-current-frame img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    border: 5px solid #11182b;
    border-radius: 50%;
    background: #0b1020;
}

.avatar-current-info {
    display: grid;
    gap: 7px;
}

.avatar-current-info strong {
    color: #ffffff;
    font-size: 1.2rem;
}

.avatar-current-info span {
    max-width: 280px;
    color: #8f9bb2;
    font-size: 0.84rem;
    line-height: 1.6;
}

.avatar-upload-zone {
    min-height: 310px;
    padding: clamp(24px, 4vw, 36px);
    display: grid;
    grid-template-columns: 130px minmax(0, 1fr);
    align-items: center;
    gap: 28px;
    border: 2px dashed rgba(93, 132, 255, 0.32);
    border-radius: 20px;
    cursor: pointer;
    background:
        linear-gradient(
            145deg,
            rgba(93, 132, 255, 0.08),
            rgba(8, 13, 25, 0.48)
        );
    transition:
        border-color 0.2s ease,
        background 0.2s ease,
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

.avatar-upload-zone:hover {
    border-color: rgba(93, 132, 255, 0.62);
    background:
        linear-gradient(
            145deg,
            rgba(93, 132, 255, 0.13),
            rgba(8, 13, 25, 0.62)
        );
}

.avatar-upload-zone.is-dragging {
    border-color: #7ea0ff;
    background: rgba(79, 124, 255, 0.14);
    box-shadow: 0 0 0 5px rgba(79, 124, 255, 0.1);
    transform: scale(1.01);
}

.avatar-upload-zone.has-file {
    border-style: solid;
    border-color: rgba(74, 222, 128, 0.45);
    background:
        linear-gradient(
            145deg,
            rgba(74, 222, 128, 0.08),
            rgba(8, 13, 25, 0.58)
        );
}

.avatar-upload-preview {
    width: 130px;
    height: 130px;
    padding: 4px;
    overflow: hidden;
    border-radius: 50%;
    background:
        linear-gradient(
            135deg,
            #5d84ff,
            #315cda
        );
    box-shadow: 0 14px 34px rgba(49, 92, 218, 0.22);
}

.avatar-upload-preview img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    border: 4px solid #11182b;
    border-radius: 50%;
    background: #0b1020;
}

.avatar-upload-content {
    min-width: 0;
    display: grid;
    justify-items: start;
    gap: 10px;
}

.avatar-upload-content strong {
    color: #ffffff;
    font-size: clamp(1.05rem, 2vw, 1.25rem);
}

.avatar-upload-content span {
    color: #8f9bb2;
    font-size: 0.85rem;
    line-height: 1.6;
}

.avatar-upload-content small {
    max-width: 100%;
    overflow: hidden;
    color: #7f8da8;
    font-size: 0.76rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.avatar-upload-zone.has-file .avatar-upload-content small {
    color: #86efac;
}

.form-help-box {
    padding: 16px 18px;
    border: 1px solid rgba(93, 132, 255, 0.18);
    border-radius: 14px;
    background: rgba(79, 124, 255, 0.065);
}

.form-help-box strong {
    display: block;
    margin-bottom: 6px;
    color: #dbe5ff;
    font-size: 0.84rem;
}

.form-help-box p {
    margin: 0;
    color: #8f9bb2;
    font-size: 0.78rem;
    line-height: 1.6;
}

.form-alert {
    margin-bottom: 22px;
    padding: 16px 18px;
    border-radius: 14px;
}

.form-alert strong {
    display: block;
    margin-bottom: 8px;
}

.form-alert ul {
    margin: 0;
    padding-left: 20px;
}

.form-alert li {
    font-size: 0.84rem;
    line-height: 1.6;
}

.form-alert-error {
    color: #fecaca;
    border: 1px solid rgba(248, 113, 113, 0.28);
    background: rgba(127, 29, 29, 0.24);
}

.form-alert-success {
    color: #bbf7d0;
    border: 1px solid rgba(74, 222, 128, 0.24);
    background: rgba(20, 83, 45, 0.25);
}

.form-actions {
    margin-top: 4px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    flex-wrap: wrap;
}

.button {
    min-height: 48px;
    padding: 0 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid transparent;
    border-radius: 13px;
    cursor: pointer;
    text-decoration: none;
    font: inherit;
    font-size: 0.88rem;
    font-weight: 800;
    transition:
        transform 0.2s ease,
        background 0.2s ease,
        color 0.2s ease,
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.button:hover {
    transform: translateY(-1px);
}

.button-primary {
    color: #ffffff;
    border-color: rgba(93, 132, 255, 0.42);
    background:
        linear-gradient(
            135deg,
            #5d84ff,
            #315cda
        );
    box-shadow: 0 12px 26px rgba(49, 92, 218, 0.24);
}

.button-primary:hover {
    box-shadow: 0 16px 32px rgba(49, 92, 218, 0.32);
}

.button-primary:disabled {
    opacity: 0.65;
    cursor: not-allowed;
    transform: none;
}

.button-secondary {
    color: #c7d0e2;
    border-color: rgba(255, 255, 255, 0.09);
    background: rgba(255, 255, 255, 0.035);
}

.button-secondary:hover {
    color: #ffffff;
    border-color: rgba(79, 124, 255, 0.28);
    background: rgba(79, 124, 255, 0.08);
}

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

    .cms-profile-card {
        align-self: stretch;
    }
}

@media (max-width: 700px) {
    .avatar-upload-zone {
        grid-template-columns: 1fr;
        justify-items: center;
        text-align: center;
    }

    .avatar-upload-content {
        justify-items: center;
    }

    .avatar-upload-content small {
        white-space: normal;
        overflow-wrap: anywhere;
    }
}

@media (max-width: 600px) {
    .cms-form-actions,
    .form-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .cms-form-actions .cms-primary-button,
    .cms-form-actions .cms-secondary-button,
    .form-actions .button {
        width: 100%;
    }

    .avatar-upload-zone {
        min-height: 0;
        padding: 24px 18px;
    }

    .avatar-upload-preview {
        width: 110px;
        height: 110px;
    }
}

/* Pagina mesaje private */

.messages-page {
    display: grid;
    gap: 24px;
}

.messages-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
}

.messages-header h2 {
    margin: 7px 0 8px;
    color: #ffffff;
    font-size: clamp(1.5rem, 3vw, 2rem);
}

.messages-header p {
    margin: 0;
    color: #8f9bb2;
    font-size: 0.88rem;
    line-height: 1.6;
}

.section-label {
    color: #7ea0ff;
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.messages-stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.message-stat-card {
    min-width: 0;
    padding: 20px;
    display: grid;
    gap: 8px;
    border: 1px solid rgba(255, 255, 255, 0.075);
    border-radius: 17px;
    background:
        linear-gradient(
            180deg,
            rgba(20, 29, 49, 0.98),
            rgba(16, 23, 40, 0.98)
        );
    box-shadow: 0 14px 36px rgba(0, 0, 0, 0.14);
}

.message-stat-card span {
    color: #8f9bb2;
    font-size: 0.78rem;
    font-weight: 700;
}

.message-stat-card strong {
    color: #ffffff;
    font-size: 1.8rem;
}

.messages-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
    align-items: start;
}

.messages-card {
    min-width: 0;
    overflow: hidden;
    padding: 0;
    border: 1px solid rgba(255, 255, 255, 0.075);
    border-radius: 20px;
    background:
        linear-gradient(
            180deg,
            rgba(20, 29, 49, 0.98),
            rgba(16, 23, 40, 0.98)
        );
    box-shadow: 0 18px 48px rgba(0, 0, 0, 0.18);
}

.messages-card-header {
    min-height: 90px;
    padding: 22px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.065);
}

.messages-card-header h3 {
    margin: 6px 0 0;
    color: #ffffff;
    font-size: 1.12rem;
}

.messages-unread-badge {
    flex-shrink: 0;
    padding: 7px 10px;
    border: 1px solid rgba(93, 132, 255, 0.28);
    border-radius: 999px;
    color: #cdd9ff;
    background: rgba(79, 124, 255, 0.12);
    font-size: 0.72rem;
    font-weight: 800;
}

.messages-list {
    display: grid;
}

.message-item {
    min-width: 0;
    padding: 17px 20px;
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr);
    align-items: center;
    gap: 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.055);
    color: inherit;
    text-decoration: none;
    background: transparent;
    transition:
        background 0.2s ease,
        transform 0.2s ease;
}

.message-item:last-child {
    border-bottom: 0;
}

.message-item:hover {
    background: rgba(79, 124, 255, 0.075);
}

.message-item.is-unread {
    background:
        linear-gradient(
            90deg,
            rgba(79, 124, 255, 0.13),
            rgba(79, 124, 255, 0.035)
        );
    box-shadow: inset 3px 0 0 #5d84ff;
}

.message-item.is-unread:hover {
    background:
        linear-gradient(
            90deg,
            rgba(79, 124, 255, 0.18),
            rgba(79, 124, 255, 0.065)
        );
}

.message-avatar {
    width: 48px;
    height: 48px;
    display: block;
    object-fit: cover;
    border: 2px solid rgba(93, 132, 255, 0.35);
    border-radius: 50%;
    background: #0b1020;
}

.message-item-content {
    min-width: 0;
    display: grid;
    gap: 6px;
}

.message-item-top {
    min-width: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.message-item-top strong {
    min-width: 0;
    overflow: hidden;
    color: #edf2ff;
    font-size: 0.86rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.message-item-top time {
    flex-shrink: 0;
    color: #71809c;
    font-size: 0.68rem;
}

.message-subject {
    min-width: 0;
    overflow: hidden;
    color: #9da9bd;
    font-size: 0.8rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.message-item.is-unread .message-subject {
    color: #dbe5ff;
    font-weight: 700;
}

.message-status {
    width: fit-content;
    padding: 4px 7px;
    border-radius: 999px;
    color: #cdd9ff;
    background: rgba(79, 124, 255, 0.14);
    font-size: 0.65rem;
    font-weight: 900;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.messages-empty {
    min-height: 280px;
    padding: 38px 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    text-align: center;
}

.messages-empty-icon {
    width: 64px;
    height: 64px;
    margin-bottom: 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(93, 132, 255, 0.2);
    border-radius: 18px;
    color: #7ea0ff;
    background: rgba(79, 124, 255, 0.08);
    font-size: 1.6rem;
}

.messages-empty h4 {
    margin: 0 0 8px;
    color: #ffffff;
    font-size: 1rem;
}

.messages-empty p {
    max-width: 300px;
    margin: 0;
    color: #7f8da8;
    font-size: 0.8rem;
    line-height: 1.6;
}

@media (max-width: 1050px) {
    .messages-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 760px) {
    .messages-stats {
        grid-template-columns: 1fr;
    }

    .messages-header {
        align-items: stretch;
        flex-direction: column;
    }

    .messages-header .button {
        width: 100%;
    }
}

@media (max-width: 560px) {
    .messages-card-header {
        padding: 19px 17px;
    }

    .message-item {
        padding: 15px 16px;
        grid-template-columns: 42px minmax(0, 1fr);
        gap: 11px;
    }

    .message-avatar {
        width: 42px;
        height: 42px;
    }

    .message-item-top {
        align-items: flex-start;
        flex-direction: column;
        gap: 4px;
    }

    .message-item-top time {
        font-size: 0.65rem;
    }

    .messages-unread-badge {
        font-size: 0.66rem;
    }
}

/* Textarea pentru formulare */

.cms-form-group textarea {
    width: 100%;
    min-height: 220px;
    padding: 14px;
    resize: vertical;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    outline: none;
    color: #ffffff;
    background: rgba(8, 13, 25, 0.72);
    font: inherit;
    line-height: 1.6;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        background 0.2s ease;
}

.cms-form-group textarea:focus {
    border-color: #5d84ff;
    background: rgba(8, 13, 25, 0.9);
    box-shadow: 0 0 0 4px rgba(79, 124, 255, 0.14);
}

.cms-form-group textarea::placeholder {
    color: #65728c;
}
/* Pagina citire mesaj privat */

.message-view-page {
    display: grid;
    gap: 22px;
}

.message-view-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    flex-wrap: wrap;
}

.message-view-card {
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.075);
    border-radius: 20px;
    background:
        linear-gradient(
            180deg,
            rgba(20, 29, 49, 0.98),
            rgba(16, 23, 40, 0.98)
        );
    box-shadow: 0 18px 48px rgba(0, 0, 0, 0.18);
}

.message-view-card-header {
    padding: 22px 24px;
    display: grid;
    grid-template-columns: 58px minmax(0, 1fr) auto;
    align-items: center;
    gap: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.065);
}

.message-view-avatar {
    width: 58px;
    height: 58px;
    display: block;
    object-fit: cover;
    border: 3px solid rgba(93, 132, 255, 0.35);
    border-radius: 50%;
    background: #0b1020;
}

.message-view-user {
    min-width: 0;
    display: grid;
    gap: 5px;
}

.message-view-user span {
    color: #7f8da8;
    font-size: 0.74rem;
    font-weight: 700;
}

.message-view-user strong {
    overflow: hidden;
    color: #ffffff;
    font-size: 1rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.message-view-card-header time {
    color: #7f8da8;
    font-size: 0.75rem;
}

.message-view-subject {
    padding: 24px 28px 18px;
}

.message-view-subject span {
    color: #7ea0ff;
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.message-view-subject h2 {
    margin: 8px 0 0;
    color: #ffffff;
    font-size: clamp(1.35rem, 3vw, 1.9rem);
    line-height: 1.35;
}

.message-view-body {
    min-height: 220px;
    padding: 6px 28px 32px;
    color: #c7d0e2;
    font-size: 0.92rem;
    line-height: 1.8;
    overflow-wrap: anywhere;
}

.message-delete-button {
    color: #fecaca;
    border-color: rgba(248, 113, 113, 0.28);
    background: rgba(127, 29, 29, 0.24);
}

.message-delete-button:hover {
    color: #ffffff;
    border-color: rgba(248, 113, 113, 0.5);
    background: rgba(153, 27, 27, 0.38);
}

@media (max-width: 650px) {
    .message-view-header {
        align-items: stretch;
        flex-direction: column;
    }

    .message-view-header .button,
    .message-view-header form,
    .message-view-header form button {
        width: 100%;
    }

    .message-view-card-header {
        grid-template-columns: 48px minmax(0, 1fr);
        padding: 18px;
    }

    .message-view-avatar {
        width: 48px;
        height: 48px;
    }

    .message-view-card-header time {
        grid-column: 1 / -1;
        padding-top: 4px;
    }

    .message-view-subject {
        padding: 22px 20px 16px;
    }

    .message-view-body {
        padding: 4px 20px 26px;
    }
}

/* Autocomplete utilizatori */

.user-search-wrapper {
    position: relative;
}

.user-search-results {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    z-index: 1000;

    max-height: 320px;
    overflow-y: auto;

    background: #111722;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 14px;

    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.35);
}

.user-search-results[hidden] {
    display: none;
}

.user-search-item {
    width: 100%;
    min-height: 68px;

    display: flex;
    align-items: center;
    gap: 12px;

    padding: 12px 14px;

    color: #ffffff;
    text-align: left;

    background: transparent;
    border: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);

    cursor: pointer;

    transition:
        background-color 0.2s ease,
        transform 0.2s ease;
}

.user-search-item:last-child {
    border-bottom: 0;
}

.user-search-item:hover,
.user-search-item:focus {
    background: rgba(255, 255, 255, 0.07);
    outline: none;
}

.user-search-avatar {
    width: 44px;
    height: 44px;

    flex-shrink: 0;

    object-fit: cover;

    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.12);
}

.user-search-info {
    min-width: 0;

    display: flex;
    flex: 1;
    flex-direction: column;
    gap: 4px;
}

.user-search-info strong {
    overflow: hidden;

    font-size: 15px;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.user-search-info small {
    color: #8f9bad;
    font-size: 13px;
}

.user-status-dot {
    width: 10px;
    height: 10px;

    flex-shrink: 0;

    border-radius: 50%;
}

.user-status-dot.is-online {
    background: #35d07f;
    box-shadow: 0 0 10px rgba(53, 208, 127, 0.55);
}

.user-status-dot.is-offline {
    background: #687386;
}

.user-search-empty {
    padding: 18px;

    color: #8f9bad;
    font-size: 14px;
    text-align: center;
}

@media (max-width: 650px) {
    .user-search-results {
        max-height: 260px;
    }

    .user-search-item {
        min-height: 62px;
        padding: 10px 12px;
    }

    .user-search-avatar {
        width: 40px;
        height: 40px;
    }
}

/* ==========================================================
   AUTH — LOGIN / REGISTER
========================================================== */

.auth-page {
    min-height: calc(100vh - 156px);
    padding: 64px 20px;
    display: grid;
    place-items: center;
    background:
        radial-gradient(
            circle at 15% 20%,
            rgba(47, 124, 255, 0.16),
            transparent 30%
        ),
        radial-gradient(
            circle at 85% 20%,
            rgba(255, 122, 26, 0.14),
            transparent 30%
        ),
        linear-gradient(
            180deg,
            #070a10,
            #0a0f19
        );
}

.auth-shell {
    width: min(100%, 560px);
}

.auth-card {
    width: 100%;
    padding: clamp(24px, 4vw, 42px);
    border: 1px solid rgba(255, 255, 255, 0.10);
    border-radius: 24px;
    background:
        linear-gradient(
            180deg,
            rgba(15, 20, 31, 0.96),
            rgba(8, 12, 20, 0.98)
        );
    box-shadow:
        0 30px 90px rgba(0, 0, 0, 0.46),
        inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.auth-header {
    margin-bottom: 28px;
    text-align: center;
}

.welcome-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    padding: 8px 14px;
    border: 1px solid rgba(242, 201, 76, 0.30);
    border-radius: 999px;
    color: #f2c94c;
    background: rgba(242, 201, 76, 0.07);
    font-size: 11px;
    font-weight: 900;
    letter-spacing: 1.5px;
}

.auth-header h1 {
    margin: 0;
    color: #ffffff;
    font-size: clamp(30px, 5vw, 44px);
    font-weight: 950;
    line-height: 1.05;
}

.auth-header p {
    max-width: 440px;
    margin: 14px auto 0;
    color: #9ca7ba;
    font-size: 14px;
    line-height: 1.65;
}

.auth-form {
    display: grid;
    gap: 18px;
}

.form-group {
    display: grid;
    gap: 8px;
}

.form-group label {
    color: #dce2ed;
    font-size: 13px;
    font-weight: 800;
}

.form-group input {
    width: 100%;
    height: 52px;
    padding: 0 16px;
    border: 1px solid rgba(255, 255, 255, 0.11);
    border-radius: 13px;
    outline: none;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.045);
    font: inherit;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        background 0.2s ease;
}

.form-group input::placeholder {
    color: #697387;
}

.form-group input:hover {
    border-color: rgba(255, 255, 255, 0.20);
    background: rgba(255, 255, 255, 0.06);
}

.form-group input:focus {
    border-color: rgba(242, 201, 76, 0.72);
    background: rgba(255, 255, 255, 0.065);
    box-shadow:
        0 0 0 4px rgba(242, 201, 76, 0.10),
        0 0 28px rgba(242, 201, 76, 0.08);
}

.auth-button {
    min-height: 54px;
    margin-top: 6px;
    border: 1px solid rgba(242, 201, 76, 0.82);
    border-radius: 13px;
    color: #10141d;
    background:
        linear-gradient(
            135deg,
            #ffe06f,
            #d9aa1e
        );
    font-size: 14px;
    font-weight: 950;
    cursor: pointer;
    transition:
        transform 0.2s ease,
        filter 0.2s ease,
        box-shadow 0.2s ease;
}

.auth-button:hover {
    transform: translateY(-2px);
    filter: brightness(1.06);
    box-shadow: 0 16px 34px rgba(242, 201, 76, 0.18);
}

.auth-button:active {
    transform: translateY(0);
}

.auth-footer,
.auth-back {
    margin: 18px 0 0;
    text-align: center;
    color: #929cad;
    font-size: 13px;
}

.auth-back {
    margin-top: 12px;
}

.auth-footer a,
.auth-back a {
    color: #f2c94c;
    font-weight: 800;
    text-decoration: none;
}

.auth-footer a:hover,
.auth-back a:hover {
    color: #ffe58c;
    text-decoration: underline;
}

.alert {
    margin-bottom: 20px;
    padding: 14px 16px;
    border-radius: 13px;
}

.alert p {
    margin: 0;
}

.alert p + p {
    margin-top: 6px;
}

.alert-error {
    border: 1px solid rgba(255, 95, 109, 0.28);
    color: #ffadb6;
    background: rgba(255, 95, 109, 0.09);
}

@media (max-width: 680px) {
    .auth-page {
        min-height: calc(100vh - 84px);
        padding: 30px 12px;
    }

    .auth-card {
        padding: 24px 18px;
        border-radius: 18px;
    }

    .auth-header h1 {
        font-size: 32px;
    }

    .form-group input {
        height: 50px;
    }
}
