/* ========================================
   BeProf Portal - Area Riservata
   Global Styles
   ======================================== */

:root {
    --bp-primary: #193760;
    --bp-primary-light: #9db6da;
    --bp-accent: #e9a23b;
    --bp-body-bg: #f5f6fa;
    --bp-header-bg: #f6f7f9;
    --bp-border: #d9d9d9;
    --bp-input-border: #ced2d6;
    --bp-text-dark: #24292e;
    --bp-text-body: #454c52;
    --bp-text-muted: #9ea5ad;
    --bp-radius: 12px;
    --bp-radius-sm: 8px;
    --bp-shadow: 0 4px 20px rgba(0,0,0,0.08);
    --bp-success-bg: #d9f9e6;
    --bp-success-border: #b8f1d2;
    --bp-success-text: #53b483;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Nunito', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: var(--bp-text-dark);
    background: var(--bp-body-bg);
}

/* ========================================
   LOGIN PAGE
   ======================================== */
.login-body {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #e8ecf2;
    padding: 20px;
}

.login-wrapper {
    width: 100%;
    max-width: 960px;
}

.login-card {
    display: flex;
    background: #fff;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--bp-shadow);
    min-height: 600px;
}

.login-left {
    flex: 1;
    padding: 48px 40px;
    display: flex;
    flex-direction: column;
    background: #fff;
}

.login-logo {
    height: 48px;
    width: auto;
    margin-bottom: 32px;
    object-fit: contain
}

.login-heading {
    font-size: 28px;
    font-weight: 700;
    color: var(--bp-primary);
    line-height: 1.25;
    margin-bottom: 12px;
}

.login-tagline {
    font-size: 15px;
    color: var(--bp-text-muted);
    line-height: 1.5;
    max-width: 320px;
}

.login-illustration {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    margin-top: 24px;
}

.illustration-circle {
    width: 220px;
    height: 220px;
    border-radius: 50%;
    background: #fbf2cb;
    position: absolute;
}

.illustration-phone {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.illustration-cards {
    display: flex;
    gap: 4px;
    margin-top: -10px;
}

.illustration-card {
    background: #fff;
    border: 1px solid #e5e7ea;
    border-radius: 6px;
    padding: 6px 10px;
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    font-weight: 700;
    color: var(--bp-primary);
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.login-right {
    flex: 1;
    padding: 48px 40px;
    display: flex;
    flex-direction: column;
    background: var(--bp-header-bg);
    border-left: 1px solid #edf0f4;
}

.login-form-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--bp-text-dark);
    text-align: center;
    margin-bottom: 28px;
}

.form-group {
    margin-bottom: 16px;
}

.form-label-bp {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: var(--bp-text-dark);
    margin-bottom: 6px;
}

.input-bp {
    width: 100%;
    height: 46px;
    border: 1px solid var(--bp-input-border);
    border-radius: var(--bp-radius);
    padding: 0 16px;
    font-size: 15px;
    color: var(--bp-text-dark);
    background: #fff;
    outline: none;
    transition: border-color 0.2s;
    font-family: inherit;
}

    .input-bp:focus {
        border-color: var(--bp-primary);
        box-shadow: 0 0 0 3px rgba(25, 55, 96, 0.1);
    }

    .input-bp::placeholder {
        color: var(--bp-text-muted);
    }

.password-wrapper {
    position: relative;
}

.password-toggle {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    color: var(--bp-text-muted);
    padding: 0;
    display: flex;
}

    .password-toggle:hover {
        color: var(--bp-primary);
    }

.remember-row {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: var(--bp-text-dark);
    margin-bottom: 20px;
    cursor: pointer;
}

.remember-check {
    width: 18px;
    height: 18px;
    accent-color: var(--bp-primary);
    cursor: pointer;
}

.btn-accedi {
    width: 100%;
    height: 46px;
    background: var(--bp-primary);
    color: #fff;
    border: none;
    border-radius: var(--bp-radius);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    margin-bottom: 12px;
    font-family: inherit;
}

    .btn-accedi:hover {
        background: #142d50;
    }

.forgot-link {
    display: block;
    text-align: center;
    font-size: 14px;
    color: var(--bp-primary);
    text-decoration: none;
    font-weight: 500;
    margin-bottom: 20px;
}

    .forgot-link:hover {
        text-decoration: underline;
    }

.divider-or {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
    color: var(--bp-text-muted);
    font-size: 14px;
}

    .divider-or::before,
    .divider-or::after {
        content: '';
        flex: 1;
        height: 1px;
        background: var(--bp-border);
    }

.btn-social {
    width: 100%;
    height: 44px;
    background: #fff;
    border: 1px solid var(--bp-input-border);
    border-radius: var(--bp-radius);
    font-size: 14px;
    font-weight: 500;
    color: var(--bp-text-dark);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 10px;
    transition: border-color 0.2s, background 0.2s;
    font-family: inherit;
}

    .btn-social:hover {
        border-color: var(--bp-primary);
        background: #f9fafc;
    }

.social-icon {
    flex-shrink: 0;
}

.register-row {
    text-align: center;
    margin-top: 16px;
    font-size: 14px;
    color: var(--bp-text-muted);
}

.register-link {
    display: block;
    margin-top: 4px;
    color: var(--bp-accent);
    text-decoration: none;
    font-weight: 600;
}

    .register-link:hover {
        text-decoration: underline;
    }

@media (max-width: 768px) {
    .login-card {
        flex-direction: column;
    }

    .login-left {
        padding: 32px 24px 16px;
    }

    .login-illustration {
        display: none;
    }

    .login-right {
        padding: 24px;
        border-left: none;
        border-top: 1px solid #edf0f4;
    }
}

/* ========================================
   PORTAL NAVBAR
   ======================================== */
.portal-navbar {
    background: #fff;
    border-bottom: 1px solid #edf0f4;
    position: sticky;
    top: 0;
    z-index: 100;
}

.portal-navbar-inner {
    max-width: 1320px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    padding: 0 24px;
    height: 64px;
    gap: 24px;
}

.portal-logo img {
    height: 36px;
}

.portal-nav {
    display: flex;
    align-items: center;
    gap: 4px;
    flex: 1;
}

.portal-nav-link {
    padding: 8px 16px;
    font-size: 14px;
    font-weight: 600;
    color: var(--bp-text-dark);
    text-decoration: none;
    border-radius: var(--bp-radius-sm);
    transition: background 0.2s, color 0.2s;
}

    .portal-nav-link:hover {
        background: var(--bp-body-bg);
        color: var(--bp-primary);
    }

    .portal-nav-link.active {
        font-weight: 700;
        color: var(--bp-primary);
    }

.portal-nav-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.icon-btn {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--bp-text-dark);
    padding: 6px;
    border-radius: 8px;
    position: relative;
    display: flex;
}

    .icon-btn:hover {
        background: var(--bp-body-bg);
    }

.notification-dot {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 8px;
    height: 8px;
    background: #f34141;
    border-radius: 50%;
}

.portal-user {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: 8px;
}

.portal-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
}

.portal-user-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--bp-text-dark);
}

.portal-hamburger {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--bp-text-dark);
    padding: 6px;
    margin-left: auto;
}

/* ========================================
   PORTAL MAIN CONTENT
   ======================================== */
.portal-main {
    max-width: 1320px;
    margin: 0 auto;
    padding: 24px;
}

.portal-welcome {
    font-size: 24px;
    font-weight: 700;
    color: var(--bp-text-dark);
    margin-bottom: 24px;
}

.portal-grid {
    display: grid;
    grid-template-columns: 1fr 450px;
    gap: 24px;
    align-items: start;
}

.portal-col-main {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.portal-col-side {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* ========================================
   PORTAL CARDS
   ======================================== */
.portal-card {
    background: #fff;
    border-radius: var(--bp-radius);
    padding: 20px;
    box-shadow: var(--bp-shadow);
}

.portal-card--half {
    flex: 1;
    min-width: 0;
    padding: 8px 16px;
}

.portal-cards-row {
    display: flex;
    gap: 24px;
}

/* Title inside card with bottom border */
.portal-card-title-wrap {
    padding: 10px 0;
    margin-bottom: 18px;
}

.portal-card-title {
    font-size: 20px;
    font-weight: 600;
    color: rgba(36, 41, 46, 0.96);
    margin: 0;
}

/* Header row: title + button, with bottom border */
.portal-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 10px;
    margin-bottom: 12px;
    border-bottom: 1px solid var(--bp-border);
}

.portal-card-header--bordered {
    border-bottom: 1px solid var(--bp-border);
}

/* ========================================
   BUTTONS
   ======================================== */
.btn-primary-bp {
    background: var(--bp-primary);
    color: #fff;
    border: none;
    border-radius: var(--bp-radius);
    padding: 10px 24px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    font-family: inherit;
    white-space: nowrap;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 121px;
}

    .btn-primary-bp:hover {
        background: #142d50;
    }

/* ========================================
   CIRCLE PROGRESS
   ======================================== */
.level-card-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.level-checklist {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 0 4px;
}

.level-check {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 18px;
    font-weight: 400;
}

    .level-check .material-symbols-outlined {
        font-size: 24px;
    }

.level-check--ok {
    color: #53b483;
}

    .level-check--ok .material-symbols-outlined {
        color: #53b483;
    }

.level-check--warn {
    color: #e9a23b;
}

    .level-check--warn .material-symbols-outlined {
        color: #e9a23b;
    }

.level-check--ko {
    color: #f34141;
}

    .level-check--ko .material-symbols-outlined {
        color: #f34141;
    }

.circle-progress {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.circle-progress-value {
    position: absolute;
    font-size: 50px;
    font-weight: 600;
    color: var(--bp-primary);
}

.circle-progress-value--emoji {
    font-size: inherit;
}

/* ========================================
   PORTAL TABLE
   ======================================== */
.portal-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 16px;
}

    .portal-table th {
        text-align: center;
        font-weight: 400;
        color: var(--bp-text-dark);
        padding: 16px 8px;
        border-bottom: 1px solid var(--bp-border);
        font-size: 16px;
    }

    .portal-table td {
        text-align: center;
        padding: 16px 8px;
        border-bottom: 1px solid var(--bp-border);
        color: var(--bp-text-dark);
        font-size: 16px;
    }

    .portal-table tbody tr:last-child td {
        border-bottom: 1px solid var(--bp-border);
    }

.badge-portal {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 10px;
    border-radius: var(--bp-radius-sm);
    font-size: 12px;
    font-weight: 600;
    height: 22px;
    width:max-content;
}

.badge-portal--attivo {
    background: var(--bp-success-bg);
    border: 1px solid var(--bp-success-border);
    color: var(--bp-success-text);
}

.badge-portal--pausa {
    background: #e6e6e6;
    border: 1px solid var(--bp-text-muted);
    color: var(--bp-text-muted);
}

.badge-portal--sconto {
    background: #fff2d7;
    border: 1px solid #f8c045;
    color: #f8c045;
}

/* ========================================
   RECOMMENDED / PRODUCT CARDS
   ======================================== */
.recommended-row {
    display: flex;
    gap: 40px;
    padding: 16px 0;
}

.recommended-card {
    flex: 1;
    border: 1.5px solid #e6e6e6;
    border-radius: 0 0 16px 16px;
    overflow: hidden;
    cursor: pointer;
    transition: box-shadow 0.2s;
}

    .recommended-card:hover {
        box-shadow: 0 4px 16px rgba(0,0,0,0.08);
    }

.recommended-img {
    height: 201px;
    background: var(--bp-primary);
    display: flex;
    align-items: center;
    justify-content: center;
}

.recommended-body {
    padding: 16px 15px 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.recommended-label {
    font-size: 16px;
    font-weight: 600;
    color: var(--bp-text-dark);
    padding: 0 8px;
}

.recommended-desc {
    font-size: 14px;
    font-weight: 300;
    color: var(--bp-text-dark);
    line-height: 1.5;
    padding: 0 8px;
}

.recommended-price-row {
    display: flex;
    align-items: flex-end;
    gap: 63px;
    padding: 0 8px;
}

.recommended-price {
    font-size: 16px;
    font-weight: 600;
    color: var(--bp-text-dark);
}

.recommended-btn {
    width: 100%;
    padding: 10px 16px;
    font-size: 14px;
}

/* ========================================
   CALENDARIO EVENTS
   ======================================== */
.portal-events {
    display: flex;
    flex-direction: column;
}

.portal-event {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 8px;
    border-bottom: 1px solid var(--bp-border);
}

    .portal-event:last-child {
        border-bottom: 1px solid var(--bp-border);
    }

.portal-event-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

    .portal-event-icon .material-symbols-outlined {
        font-size: 24px;
    }

.portal-event-icon--red {
    background: none;
}

    .portal-event-icon--red .material-symbols-outlined {
        font-size: 36px;
        color: #f34141;
    }

.portal-event-icon--blue {
    background: #cbdffb;
}

    .portal-event-icon--blue .material-symbols-outlined {
        color: var(--bp-primary);
    }

.portal-event-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.portal-event-name {
    font-size: 16px;
    font-weight: 500;
    color: var(--bp-text-dark);
    margin-bottom:0
}

.portal-event-meta {
    font-size: 14px;
    font-weight: 300;
    color: var(--bp-text-dark);
    display: flex;
    align-items: center;
    gap: 10px;
}

    .portal-event-meta .material-symbols-outlined {
        font-size: 20px;
    }

/* ========================================
   DOCUMENTI
   ======================================== */
.portal-docs {
    display: flex;
    flex-direction: column;
}

.portal-doc {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 10px 8px;
    border-bottom: 1px solid var(--bp-border);
}

.portal-doc-icon {
    font-size: 36px;
    color: var(--bp-text-muted);
}

.portal-doc-name {
    flex: 1;
    font-size: 16px;
    font-weight: 400;
    color: var(--bp-text-dark);
}

.portal-doc-date {
    font-size: 16px;
    font-weight: 600;
    color: var(--bp-text-dark);
}

/* ========================================
   COMMUNITY CHAT
   ======================================== */
.community-chat {
    display: flex;
    gap: 11px;
}

.community-timeline {
    width: 16px;
    flex-shrink: 0;
    background: linear-gradient(to bottom, var(--bp-primary) 0%, var(--bp-primary) 50%, var(--bp-accent) 50%, var(--bp-accent) 100%);
    border-radius: 8px;
    position: relative;
}

    .community-timeline::before,
    .community-timeline::after {
        content: '';
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
        width: 10px;
        height: 10px;
        border-radius: 50%;
        border: 2px solid #fff;
    }

    .community-timeline::before {
        top: 0;
        background: var(--bp-primary);
    }

    .community-timeline::after {
        top: 50%;
        background: var(--bp-accent);
    }

.community-messages {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.community-msg {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.community-msg-header {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 16px;
}

.community-avatar {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    object-fit: cover;
}

.community-time {
    color: var(--bp-text-dark);
    font-size: 16px;
    font-weight: 400;
}

.community-msg-text {
    font-size: 16px;
    font-weight: 600;
    color: var(--bp-text-body);
    line-height: 22px;
    padding: 16px 0;
}

/* ========================================
   NEWS
   ======================================== */
.portal-news {
    display: flex;
    flex-direction: column;
}

.portal-news-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 8px;
    border-bottom: 1px solid var(--bp-border);
}

.portal-news-thumb {
    width: 91px;
    height: 58px;
    border-radius: var(--bp-radius-sm);
    background: var(--bp-primary);
    flex-shrink: 0;
    overflow: hidden;
}

    .portal-news-thumb img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

.portal-news-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.portal-news-title {
    font-size: 16px;
    font-weight: 500;
    color: var(--bp-text-dark);
}

/* ========================================
   RESPONSIVE
   ======================================== */
@media (max-width: 1200px) {
    .portal-grid {
        grid-template-columns: 1fr 350px;
    }

    .recommended-row {
        gap: 20px;
    }
}

@media (max-width: 992px) {
    .portal-grid {
        grid-template-columns: 1fr;
    }

    .portal-nav-actions {
        display: none;
    }

    .portal-hamburger {
        display: flex;
    }

    .portal-nav {
        display: none;
        position: absolute;
        top: 64px;
        left: 0;
        right: 0;
        background: #fff;
        flex-direction: column;
        padding: 16px;
        border-bottom: 1px solid #edf0f4;
        box-shadow: var(--bp-shadow);
    }

        .portal-nav.show {
            display: flex;
        }

    .portal-nav-link {
        padding: 12px 16px;
    }
}

@media (max-width: 640px) {
    .portal-cards-row {
        flex-direction: column;
    }

    .recommended-row {
        flex-direction: column;
        gap: 16px;
    }

    .portal-main {
        padding: 16px;
    }
}

.login-right > div {
    flex: 1;
    padding: 15px 20px;
    display: flex;
    flex-direction: column;
    background: #fff;
    border-radius: 12px
}
.form-alert {
    background: #fdecea;
    color: #b42318;
    border: 1px solid #f5c2c7;
    padding: 12px 14px;
    border-radius: 6px;
    margin-bottom: 15px;
    font-size: 14px;
}