/* =================== PROFILE =================== */
.profile-section {
    background: var(--white);
    border-radius: 8px;
    padding: 1.25rem;
    margin-bottom: 1rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.profile-name {
    font-size: 1.2rem;
    font-weight: 600;
    color: #333;
}

.profile-detail {
    font-size: 0.85rem;
    color: #666;
    margin-top: 0.3rem;
}

/* =================== COMPANY INFO CARD (Home) =================== */
.company-info-card {
    background: var(--white);
    border-radius: 12px;
    padding: 1.25rem;
    margin-bottom: 0.75rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.company-info-header {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.company-info-logo {
    width: 80px;
    height: 80px;
    min-width: 80px;
    border-radius: 12px;
    object-fit: cover;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.company-info-main {
    flex: 1;
    min-width: 0;
}

.company-info-name {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

.company-info-name:empty {
    display: none;
}

.company-info-body {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.company-info-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.4rem;
    font-size: 0.85rem;
    color: #4b5563;
}

.company-info-row span {
    word-break: break-word;
}

.company-info-icon {
    width: 28px;
    height: 28px;
    min-width: 28px;
    border-radius: 50%;
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 0.7rem;
}

.company-info-description {
    margin-top: 1rem;
    padding-top: 0.75rem;
    border-top: 1px solid #f3f4f6;
    font-size: 0.85rem;
    color: #6b7280;
    line-height: 1.6;
}

.btn-copy,
.btn-map {
    margin-left: auto;
    background: none;
    border: none;
    color: var(--gray-light);
    font-size: 0.75rem;
    cursor: pointer;
    padding: 0.25rem;
    border-radius: 4px;
    transition: color 0.2s;
    text-decoration: none;
    display: flex;
    align-items: center;
}

.btn-copy:hover,
.btn-map:hover {
    color: var(--primary-color);
}

.btn-copy .fa-check {
    color: var(--success);
}

@media (max-width: 375px) {
    .company-info-logo {
        width: 60px;
        height: 60px;
        min-width: 60px;
    }

    .company-info-name {
        font-size: 1rem;
    }

    .company-info-row {
        font-size: 0.8rem;
    }

    .company-info-icon {
        width: 24px;
        height: 24px;
        min-width: 24px;
        font-size: 0.6rem;
    }
}

/* =================== HOME VIEW (Redesign) =================== */
.home-view {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 0.5rem 0;
}

/* Greeting */
.home-greeting {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--dark);
    padding: 0.25rem 0;
}

/* Section Header */
.home-section-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.home-section-header h2 {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1f2937;
    margin: 0;
}

.home-section-subtitle {
    font-size: 0.85rem;
    color: #6b7280;
    margin: 0.15rem 0 0;
}

/* Content Area */
.home-content-area {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

/* Quick Actions Grid */
.home-quick-actions {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    margin-top: 0.5rem;
}

.home-quick-action-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1.25rem 0.75rem;
    background: var(--white);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1.5px solid #e5e7eb;
}

.home-quick-action-card:hover {
    border-color: #93c5fd;
    background: #f8faff;
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.home-quick-action-card:active {
    transform: translateY(0);
    box-shadow: var(--shadow-sm);
}

.home-quick-action-icon {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-color) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 1.1rem;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
}

.home-quick-action-label {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--dark);
    text-align: center;
}

/* =================== HOME VIEW RESPONSIVE =================== */
@media (max-width: 375px) {
    .home-greeting {
        font-size: 1.15rem;
    }

    .home-section-header h2 {
        font-size: 1rem;
    }

    .home-section-subtitle {
        font-size: 0.8rem;
    }

    .home-quick-action-card {
        padding: 1rem 0.5rem;
    }

    .home-quick-action-icon {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }

    .home-quick-action-label {
        font-size: 0.78rem;
    }
}

@media (max-width: 320px) {
    .home-quick-actions {
        grid-template-columns: 1fr;
    }

    .home-greeting {
        font-size: 1.1rem;
    }

    .home-quick-action-card {
        flex-direction: row;
        justify-content: flex-start;
        padding: 0.85rem 1rem;
        gap: 0.75rem;
    }

    .home-quick-action-icon {
        width: 36px;
        height: 36px;
        font-size: 0.9rem;
    }
}

/* =================== EMPLOYEE HOME - Daily Stats & Bookings =================== */
.home-employee-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    background: var(--white);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

.home-employee-header-logo {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
    background: #f1f5f9;
    display: flex;
    align-items: center;
    justify-content: center;
}

.home-employee-header-logo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.home-employee-header-name {
    font-size: 0.95rem;
    font-weight: 700;
    color: #1f2937;
}

/* Today section */
.home-employee-today {
    background: var(--white);
    border-radius: var(--radius-md);
    padding: 1rem;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.home-employee-today-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #1f2937;
    margin: 0;
}

/* Stats bar (shared between daily and monthly) */
.home-employee-stats,
.home-employee-monthly-stats {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.home-employee-stat {
    flex: 1;
    min-width: 60px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.15rem;
    padding: 0.5rem 0.35rem;
    border-radius: var(--radius-sm);
}

.home-employee-stat-number {
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.2;
}

.home-employee-stat-label {
    font-size: 0.65rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.2px;
    line-height: 1.2;
}

/* Stat color variants */
.home-employee-stat-total {
    background: #eff6ff;
}
.home-employee-stat-total .home-employee-stat-number { color: var(--primary-color); }
.home-employee-stat-total .home-employee-stat-label { color: #3b82f6; }

.home-employee-stat-pending {
    background: #fffbeb;
}
.home-employee-stat-pending .home-employee-stat-number { color: #d97706; }
.home-employee-stat-pending .home-employee-stat-label { color: var(--warning); }

.home-employee-stat-completed {
    background: #f0fdf4;
}
.home-employee-stat-completed .home-employee-stat-number { color: #16a34a; }
.home-employee-stat-completed .home-employee-stat-label { color: var(--success); }

.home-employee-stat-noshow {
    background: #fef2f2;
}
.home-employee-stat-noshow .home-employee-stat-number { color: #dc2626; }
.home-employee-stat-noshow .home-employee-stat-label { color: var(--danger); }

.home-employee-stat-cancelled {
    background: #f3f4f6;
}
.home-employee-stat-cancelled .home-employee-stat-number { color: #6b7280; }
.home-employee-stat-cancelled .home-employee-stat-label { color: #9ca3af; }

/* Booking card (compact) */
.home-employee-booking {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.65rem 0.75rem;
    background: #f9fafb;
    border-radius: var(--radius-sm);
    border-left: 3px solid transparent;
}

.home-employee-booking + .home-employee-booking {
    margin-top: 0.4rem;
}

.home-employee-booking-time {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--primary-color);
    min-width: 72px;
    flex-shrink: 0;
}

.home-employee-booking-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    min-width: 0;
}

.home-employee-booking-client {
    font-size: 0.82rem;
    font-weight: 600;
    color: #1f2937;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.home-employee-booking-service {
    font-size: 0.75rem;
    color: #6b7280;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.home-employee-booking-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}

/* =================== EMPLOYEE HOME - Monthly Summary =================== */
.home-employee-monthly {
    background: var(--white);
    border-radius: var(--radius-md);
    padding: 1rem;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.home-employee-monthly-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #1f2937;
    margin: 0;
}

/* Services Breakdown */
.home-services-breakdown {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 0.5rem 0;
}

.home-service-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.4rem 0.75rem;
    background: #eff6ff;
    color: var(--primary-color);
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 500;
}

.home-service-pill strong {
    font-weight: 700;
    color: var(--primary-darker);
}

/* =================== EMPLOYEE HOME - Upcoming Bookings =================== */
.home-upcoming-section {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.home-upcoming-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #1f2937;
    margin: 0;
}

.home-upcoming-card {
    background: var(--white);
    border-radius: var(--radius-md);
    padding: 0.85rem 1rem;
    box-shadow: var(--shadow-sm);
    border-left: 3px solid var(--success);
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.home-upcoming-card + .home-upcoming-card {
    margin-top: 0.5rem;
}

.home-upcoming-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.home-upcoming-card-service {
    font-size: 0.88rem;
    font-weight: 700;
    color: #1f2937;
}

.home-upcoming-card-code {
    font-size: 0.72rem;
    font-weight: 500;
    color: #9ca3af;
}

.home-upcoming-card-body {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.home-upcoming-card-client {
    font-size: 0.82rem;
    font-weight: 600;
    color: #374151;
}

.home-upcoming-phone {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.home-upcoming-phone-number {
    font-size: 0.8rem;
    color: #6b7280;
}

.home-copy-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border: none;
    background: #f3f4f6;
    border-radius: 6px;
    cursor: pointer;
    color: #6b7280;
    font-size: 0.75rem;
    transition: all 0.2s ease;
    position: relative;
}

.home-copy-btn:hover {
    background: #e5e7eb;
    color: var(--primary-color);
}

.home-copy-tooltip {
    display: none;
    position: absolute;
    top: -28px;
    left: 50%;
    transform: translateX(-50%);
    background: #1f2937;
    color: #fff;
    font-size: 0.68rem;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    white-space: nowrap;
}

.home-copy-btn.copied .home-copy-tooltip {
    display: block;
    animation: fadeInOut 1.5s ease forwards;
}

@keyframes fadeInOut {
    0% { opacity: 0; transform: translateX(-50%) translateY(4px); }
    15% { opacity: 1; transform: translateX(-50%) translateY(0); }
    70% { opacity: 1; }
    100% { opacity: 0; }
}

.home-upcoming-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 0.35rem;
    border-top: 1px solid #f3f4f6;
}

.home-upcoming-card-date {
    font-size: 0.75rem;
    color: #6b7280;
}

.home-upcoming-card-time {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--primary-color);
}

/* =================== HOME - Stale/Offline Notice =================== */
.home-stale-notice {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.65rem 1rem;
    background: #fffbeb;
    border: 1px solid #fde68a;
    border-radius: var(--radius-sm);
    color: #92400e;
    font-size: 0.8rem;
    font-weight: 500;
    margin-bottom: 0.75rem;
}

.home-stale-notice-icon {
    flex-shrink: 0;
    font-size: 0.9rem;
}

/* =================== EMPLOYEE HOME - Responsive =================== */
@media (max-width: 375px) {
    .home-employee-header {
        padding: 0.7rem 0.85rem;
    }

    .home-employee-header-logo {
        width: 36px;
        height: 36px;
    }

    .home-employee-header-name {
        font-size: 0.88rem;
    }

    .home-employee-stat {
        min-width: 50px;
        padding: 0.4rem 0.25rem;
    }

    .home-employee-stat-number {
        font-size: 0.92rem;
    }

    .home-employee-stat-label {
        font-size: 0.6rem;
    }

    .home-employee-booking-time {
        font-size: 0.78rem;
        min-width: 64px;
    }

    .home-employee-booking-client {
        font-size: 0.78rem;
    }

    .home-employee-booking-service {
        font-size: 0.72rem;
    }

    .home-upcoming-card {
        padding: 0.75rem 0.85rem;
    }

    .home-upcoming-card-service {
        font-size: 0.82rem;
    }

    .home-service-pill {
        font-size: 0.72rem;
        padding: 0.35rem 0.6rem;
    }
}

@media (max-width: 320px) {
    .home-employee-stats,
    .home-employee-monthly-stats {
        flex-wrap: wrap;
    }

    .home-employee-stat {
        min-width: 45px;
    }

    .home-employee-booking {
        gap: 0.5rem;
    }

    .home-employee-booking-time {
        min-width: 58px;
        font-size: 0.75rem;
    }
}

/* =================== HOME SERVICES & SCHEDULE SECTIONS =================== */
.home-services-section,
.home-schedule-section {
    background: var(--white);
    border-radius: 12px;
    padding: 1.25rem;
    margin-bottom: 0.75rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

/* Section Header (icon + title) */
.home-section-icon {
    width: 36px;
    height: 36px;
    min-width: 36px;
    border-radius: 50%;
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 0.9rem;
    box-shadow: 0 3px 8px rgba(37, 99, 235, 0.25);
}

.home-section-title {
    font-size: 1rem;
    font-weight: 700;
    color: #1f2937;
    margin: 0;
}

/* Services List */
.home-services-list {
    display: flex;
    flex-direction: column;
}

/* Service Item */
.service-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid #f3f4f6;
}

.service-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.service-item:first-child {
    padding-top: 0;
}

.service-icon {
    width: 38px;
    height: 38px;
    min-width: 38px;
    border-radius: 50%;
    background: rgba(37, 99, 235, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    font-size: 0.85rem;
}

.service-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.service-name {
    font-size: 0.9rem;
    font-weight: 600;
    color: #1f2937;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.service-description {
    font-size: 0.78rem;
    color: #6b7280;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.service-arrow {
    color: #9ca3af;
    font-size: 0.75rem;
    flex-shrink: 0;
    padding-left: 0.25rem;
}

/* Schedule List */
.home-schedule-list {
    display: flex;
    flex-direction: column;
}

/* Schedule Day Row */
.schedule-day-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.6rem 0;
    border-bottom: 1px solid #f3f4f6;
}

.schedule-day-row:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.schedule-day-row:first-child {
    padding-top: 0;
}

.schedule-day-name {
    font-size: 0.88rem;
    font-weight: 600;
    color: #374151;
}

.schedule-day-hours {
    font-size: 0.85rem;
    color: #4b5563;
    font-weight: 500;
}

.schedule-day-hours.closed {
    color: var(--danger);
    font-weight: 600;
    font-size: 0.82rem;
}

/* =================== HOME SERVICES & SCHEDULE - RESPONSIVE =================== */
@media (max-width: 375px) {
    .home-services-section,
    .home-schedule-section {
        padding: 1rem;
    }

    .home-section-icon {
        width: 32px;
        height: 32px;
        min-width: 32px;
        font-size: 0.8rem;
    }

    .home-section-title {
        font-size: 0.92rem;
    }

    .service-icon {
        width: 34px;
        height: 34px;
        min-width: 34px;
        font-size: 0.8rem;
    }

    .service-name {
        font-size: 0.85rem;
    }

    .service-description {
        font-size: 0.75rem;
    }

    .schedule-day-name {
        font-size: 0.82rem;
    }

    .schedule-day-hours {
        font-size: 0.8rem;
    }
}

/* =================== PROFILE VIEW =================== */
.profile-view {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 1.5rem 1rem;
}

.profile-avatar {
    margin-bottom: 1.5rem;
}

.profile-avatar-circle {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    background: #e8edf5;
    border: 3px solid #d1d9e6;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6b83a8;
    font-size: 3rem;
}

.profile-card {
    background: var(--white);
    border-radius: 12px;
    padding: 0.5rem 1rem;
    width: 100%;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
    margin-bottom: 1.5rem;
}

.profile-field {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 0.85rem 0;
    border-bottom: 1px solid #f3f4f6;
}

.profile-field:last-child {
    border-bottom: none;
}

.profile-field-icon {
    width: 38px;
    height: 38px;
    min-width: 38px;
    border-radius: 10px;
    background: rgba(37, 99, 235, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    font-size: 0.95rem;
}

.profile-field-content {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.profile-field-label {
    font-size: 0.75rem;
    color: #9ca3af;
    font-weight: 500;
    text-transform: capitalize;
}

.profile-field-value {
    font-size: 0.95rem;
    font-weight: 700;
    color: #1f2937;
}

.btn-logout {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.85rem;
    border-radius: 12px;
    border: 1.5px solid var(--danger);
    background: rgba(239, 68, 68, 0.05);
    color: var(--danger);
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease;
}

.btn-logout:hover {
    background: rgba(239, 68, 68, 0.1);
}

.btn-logout i {
    font-size: 1rem;
}

/* =================== HOME EMPLOYEE ACCORDIONS =================== */
.home-employee-accordion {
    margin-bottom: 0.75rem;
    border-radius: 12px;
    overflow: hidden;
    background: var(--white);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.home-accordion-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    background: var(--white);
    border: none;
    width: 100%;
    cursor: pointer;
    transition: background 0.2s ease;
    font-size: 0.95rem;
    font-weight: 700;
    color: #1f2937;
}

.home-accordion-header:hover {
    background: #f9fafb;
}

.home-accordion-header span:first-of-type {
    flex: 1;
    text-align: left;
}

.home-accordion-header-icon {
    width: 36px;
    height: 36px;
    min-width: 36px;
    border-radius: 50%;
    background: rgba(37, 99, 235, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    font-size: 0.85rem;
}

.home-employee-accordion .arrow {
    transition: transform 0.2s ease;
    font-size: 0.7rem;
    color: #9ca3af;
}

.home-employee-accordion.open > .home-accordion-header .arrow {
    transform: rotate(180deg);
}

.home-employee-accordion > .accordion-body {
    padding: 0 1rem 1rem;
}

/* Copy inline button (phone in booking cards) */
.btn-copy-inline {
    background: none;
    border: none;
    color: var(--primary-color);
    font-size: 0.72rem;
    cursor: pointer;
    padding: 0.15rem 0.4rem;
    border-radius: 4px;
    margin-left: 0.3rem;
    transition: background 0.2s;
    font-weight: 500;
    vertical-align: middle;
}

.btn-copy-inline:hover {
    background: rgba(37, 99, 235, 0.1);
}

.btn-copy-inline .fa-check {
    color: var(--success);
}
