/**
 * Voicemail Portal Styles
 * RTL Support for Hebrew
 */

:root {
    --primary: #00876D;
    --primary-dark: #006d58;
    --primary-light: #00a080;
    --secondary: #152735;
    --accent: #9EF3A0;
    --background: #ffffff;
    --white: #ffffff;
    --gray-100: #f8f9fa;
    --gray-200: #e9ecef;
    --gray-300: #dee2e6;
    --gray-400: #ced4da;
    --gray-500: #adb5bd;
    --gray-600: #6c757d;
    --gray-700: #495057;
    --gray-800: #343a40;
    --danger: #dc3545;
    --success: #28a745;
    --warning: #ffc107;
    --info: #17a2b8;
    --shadow: 0 2px 10px rgba(0,0,0,0.1);
    --shadow-lg: 0 5px 20px rgba(0,0,0,0.15);
    --radius: 8px;
    --radius-lg: 12px;
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Heebo', Arial, sans-serif;
    background: var(--background);
    color: var(--secondary);
    line-height: 1.6;
}

body.lang-he {
    direction: rtl;
    text-align: right;
}

body.lang-en {
    direction: ltr;
    text-align: left;
}

/* Auth Screen */
.auth-screen {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ffffff;
    padding: 20px;
}

.auth-container {
    width: 100%;
    max-width: 420px;
}

.auth-box {
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 40px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    border: 1px solid var(--gray-200);
}

.auth-logo {
    text-align: center;
    margin-bottom: 20px;
}

.auth-logo img {
    height: 60px;
    width: auto;
}

.auth-title {
    text-align: center;
    font-size: 24px;
    font-weight: 700;
    color: var(--secondary);
    margin-bottom: 10px;
}

.auth-subtitle {
    text-align: center;
    color: var(--gray-600);
    margin-bottom: 30px;
}

.auth-lang-selector {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 20px;
}

.lang-btn {
    padding: 8px 16px;
    border: 2px solid var(--gray-300);
    background: transparent;
    color: var(--gray-700);
    border-radius: 20px;
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
}

.lang-btn.active, .lang-btn:hover {
    background: var(--primary);
    color: var(--white);
    border-color: var(--primary);
}

/* Forms */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--gray-700);
}

.form-group label i {
    margin-left: 8px;
    color: var(--primary);
}

body.lang-en .form-group label i {
    margin-left: 0;
    margin-right: 8px;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--gray-300);
    border-radius: var(--radius);
    font-size: 16px;
    font-family: inherit;
    transition: var(--transition);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(0,135,109,0.1);
}

/* Password Toggle */
.password-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.password-input-wrapper input {
    padding-left: 45px;
}

body.lang-en .password-input-wrapper input {
    padding-left: 16px;
    padding-right: 45px;
}

.password-toggle {
    position: absolute;
    left: 12px;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--gray-500);
    padding: 5px;
    transition: var(--transition);
}

body.lang-en .password-toggle {
    left: auto;
    right: 12px;
}

.password-toggle:hover {
    color: var(--primary);
}

.password-toggle i {
    font-size: 18px;
}

/* Input with Prefix */
.input-with-prefix {
    display: flex;
    align-items: stretch;
    direction: ltr;
}

.input-with-prefix .input-prefix {
    display: flex;
    align-items: center;
    padding: 12px 16px;
    background: var(--primary);
    color: white;
    font-weight: 600;
    font-size: 16px;
    border-radius: var(--radius) 0 0 var(--radius);
    border: 2px solid var(--primary);
    border-right: none;
}

.input-with-prefix input {
    flex: 1;
    border-radius: 0 var(--radius) var(--radius) 0 !important;
    direction: ltr;
    text-align: left;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border: none;
    border-radius: var(--radius);
    font-size: 16px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: var(--transition);
}

.btn-primary {
    background: var(--primary);
    color: var(--white);
}

.btn-primary:hover {
    background: var(--primary-dark);
}

.btn-secondary {
    background: var(--gray-200);
    color: var(--gray-700);
}

.btn-secondary:hover {
    background: var(--gray-300);
}

.btn-danger {
    background: var(--danger);
    color: var(--white);
}

.btn-danger:hover {
    background: #c82333;
}

.btn-success {
    background: var(--success);
    color: var(--white);
}

.btn-block {
    width: 100%;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 14px;
}

.btn-icon {
    width: 36px;
    height: 36px;
    padding: 0;
    border-radius: 50%;
}

/* Portal Layout */
.portal {
    display: block;
    min-height: 100vh;
    position: relative;
}

/* Sidebar */
.sidebar {
    width: 260px;
    background: var(--white);
    box-shadow: var(--shadow);
    padding: 20px 0;
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 100;
}

body.lang-he .sidebar {
    left: auto;
    right: 0;
}

.sidebar-header {
    padding: 20px;
    border-bottom: 1px solid var(--gray-200);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    background: var(--primary);
    text-align: center;
}

.sidebar-logo {
    height: 45px;
    width: auto;
    filter: brightness(0) invert(1);
}

.sidebar-brand {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.brand-name {
    font-size: 18px;
    font-weight: 700;
    color: var(--white);
}

.brand-subtitle {
    font-size: 12px;
    color: rgba(255,255,255,0.8);
}

.user-info {
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    border-bottom: 1px solid var(--gray-200);
}

.user-avatar {
    width: 48px;
    height: 48px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 24px;
}

.user-details {
    flex: 1;
}

.user-name {
    display: block;
    font-weight: 600;
    color: var(--secondary);
}

.user-role {
    display: block;
    font-size: 12px;
    color: var(--gray-600);
}

.sidebar-nav {
    flex: 1;
    padding: 20px 0;
    overflow-y: auto;
}

.nav-section {
    margin-bottom: 20px;
}

.nav-section-title {
    display: block;
    padding: 0 20px 10px;
    font-size: 12px;
    font-weight: 600;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    color: var(--gray-700);
    text-decoration: none;
    transition: var(--transition);
    cursor: pointer;
}

.nav-item:hover {
    background: var(--gray-100);
    color: var(--primary);
}

.nav-item.active {
    background: rgba(0,135,109,0.1);
    color: var(--primary);
    font-weight: 600;
}

.nav-item i {
    width: 20px;
    text-align: center;
}

.sidebar-footer {
    padding: 20px;
    border-top: 1px solid var(--gray-200);
}

.sidebar-lang-selector {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 15px;
}

.sidebar-lang-btn {
    padding: 6px 14px;
    border: 2px solid var(--gray-400);
    background: transparent;
    color: var(--gray-600);
    border-radius: 20px;
    cursor: pointer;
    font-weight: 600;
    font-size: 13px;
    transition: var(--transition);
}

.sidebar-lang-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.sidebar-lang-btn.active {
    background: var(--primary);
    border-color: var(--primary);
    color: var(--white);
}

/* Main Content */
.main-content {
    padding: 0;
    background: var(--background);
    height: 100vh;
    display: flex;
    flex-direction: column;
    margin-left: 260px;
    overflow: hidden;
}

body.lang-he .main-content {
    margin-left: 0;
    margin-right: 260px;
}

/* Top Header */
.top-header {
    background: var(--white);
    padding: 15px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

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

.header-brand span {
    font-size: 18px;
    font-weight: 600;
    color: var(--primary);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

.header-user {
    color: var(--gray-600);
    font-size: 14px;
}

.header-user-link {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--gray-600);
    text-decoration: none;
    padding: 6px 12px;
    border-radius: 6px;
    transition: var(--transition);
}

.header-user-link:hover {
    background: var(--gray-100);
    color: var(--primary);
}

.header-user-link i {
    font-size: 18px;
}

.header-lang-selector {
    display: flex;
    gap: 4px;
    background: var(--gray-100);
    padding: 4px;
    border-radius: 6px;
}

.header-lang-btn {
    padding: 6px 10px;
    border: none;
    background: transparent;
    color: var(--gray-600);
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    border-radius: 4px;
    transition: var(--transition);
}

.header-lang-btn:hover {
    background: var(--gray-200);
    color: var(--secondary);
}

.header-lang-btn.active {
    background: var(--primary);
    color: var(--white);
}

.page {
    display: none;
    padding: 30px;
    flex: 1;
    overflow-y: auto;
}

.page.active {
    display: block;
}

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.page-title {
    font-size: 28px;
    font-weight: 700;
    color: var(--secondary);
}

/* Cards */
.card {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    padding: 24px;
    margin-bottom: 20px;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--gray-200);
}

.card-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--secondary);
}

/* Stats Cards */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    gap: 16px;
}

.stat-icon {
    width: 56px;
    height: 56px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.stat-icon.primary {
    background: rgba(0,135,109,0.1);
    color: var(--primary);
}

.stat-icon.success {
    background: rgba(40,167,69,0.1);
    color: var(--success);
}

.stat-icon.warning {
    background: rgba(255,193,7,0.1);
    color: var(--warning);
}

.stat-icon.info {
    background: rgba(23,162,184,0.1);
    color: var(--info);
}

.stat-content {
    flex: 1;
}

.stat-value {
    font-size: 28px;
    font-weight: 700;
    color: var(--secondary);
}

.stat-label {
    font-size: 14px;
    color: var(--gray-600);
}

/* Tables */
.table-responsive {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th, td {
    padding: 14px 16px;
    text-align: inherit;
    border-bottom: 1px solid var(--gray-200);
}

th {
    font-weight: 600;
    color: var(--gray-700);
    background: var(--gray-100);
}

tr:hover {
    background: var(--gray-50);
}

/* Badges */
.badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.badge-new {
    background: rgba(0,135,109,0.1);
    color: var(--primary);
}

.badge-read {
    background: var(--gray-200);
    color: var(--gray-700);
}

.badge-deleted {
    background: rgba(220,53,69,0.1);
    color: var(--danger);
}

.badge-success {
    background: rgba(40,167,69,0.1);
    color: var(--success);
}

.badge-warning {
    background: rgba(255,193,7,0.1);
    color: #856404;
}

/* Mode Select Dropdown */
.mode-select {
    padding: 6px 12px;
    border: 2px solid var(--gray-300);
    border-radius: var(--radius);
    background: white;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 120px;
}

.mode-select:hover {
    border-color: var(--primary);
}

.mode-select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(0,135,109,0.1);
}

/* Audio Player */
.audio-player {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: var(--gray-100);
    border-radius: var(--radius);
}

.audio-player audio {
    flex: 1;
    height: 40px;
}

/* Modals */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 20px;
}

.modal.hidden {
    display: none;
}

.modal-content {
    background: var(--white);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid var(--gray-200);
}

.modal-header h3 {
    font-size: 20px;
    font-weight: 600;
}

.modal-body {
    padding: 20px;
}

.modal-footer {
    padding: 20px;
    border-top: 1px solid var(--gray-200);
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

.close-btn {
    background: none;
    border: none;
    font-size: 20px;
    color: var(--gray-600);
    cursor: pointer;
}

.close-btn:hover {
    color: var(--gray-800);
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    bottom: 20px;
    left: 20px;
    z-index: 1100;
}

body.lang-he .toast-container {
    left: auto;
    right: 20px;
}

.toast {
    background: var(--secondary);
    color: var(--white);
    padding: 16px 24px;
    border-radius: var(--radius);
    margin-top: 10px;
    display: flex;
    align-items: center;
    gap: 12px;
    animation: slideIn 0.3s ease;
}

.toast.success {
    background: var(--success);
}

.toast.error {
    background: var(--danger);
}

@keyframes slideIn {
    from {
        transform: translateX(-100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

body.lang-he .toast {
    animation-name: slideInRtl;
}

@keyframes slideInRtl {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Loading */
.loading {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid var(--gray-300);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--gray-600);
}

.empty-state i {
    font-size: 64px;
    color: var(--gray-400);
    margin-bottom: 20px;
}

.empty-state h3 {
    font-size: 20px;
    margin-bottom: 10px;
}

/* Security Log Rows */
.log-danger {
    background: rgba(220, 53, 69, 0.05);
}

.log-success {
    background: rgba(40, 167, 69, 0.05);
}

.truncate {
    max-width: 200px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

code {
    background: var(--gray-100);
    padding: 2px 6px;
    border-radius: 4px;
    font-family: monospace;
    font-size: 13px;
}

.stat-icon.danger {
    background: rgba(220, 53, 69, 0.1);
    color: var(--danger);
}

/* Form Sections (Edit Mailbox Modal) */
.form-section {
    background: var(--gray-100);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius);
    padding: 18px;
    margin-bottom: 16px;
}

.form-section-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 15px;
    font-weight: 600;
    color: var(--primary-dark);
    margin-bottom: 14px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--gray-200);
}

.form-section-title i {
    font-size: 16px;
    color: var(--primary);
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}

.form-grid .full-width {
    grid-column: 1 / -1;
}

.checkbox-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.checkbox-item {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius);
    padding: 10px 12px;
    cursor: pointer;
    transition: var(--transition);
}

.checkbox-item:hover {
    border-color: var(--primary);
    background: rgba(0, 135, 109, 0.04);
}

.checkbox-item input[type="checkbox"] {
    width: auto;
    margin: 0;
}

.checkbox-item i {
    color: var(--primary);
    font-size: 14px;
    width: 18px;
    text-align: center;
}

.checkbox-item span {
    font-size: 14px;
    color: var(--gray-700);
}

.security-row {
    display: flex;
    align-items: flex-end;
    gap: 14px;
}

.security-row .form-group {
    flex: 1;
    margin-bottom: 0;
}

.security-row .checkbox-item {
    margin-bottom: 0;
    white-space: nowrap;
    height: fit-content;
    align-self: flex-end;
}

#mailboxModal .modal-content {
    max-width: 640px;
}

/* Transcription Cell */
.transcription-cell {
    max-width: 200px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    cursor: pointer;
    transition: var(--transition);
    font-size: 13px;
    color: var(--gray-700);
}

.transcription-cell.expanded {
    white-space: normal;
    overflow: visible;
    max-width: 300px;
    background: var(--gray-100);
    border-radius: var(--radius);
    padding: 10px;
}

.transcription-cell[title]:hover {
    color: var(--primary);
}

/* Hidden */
.hidden {
    display: none !important;
}

/* Responsive */
@media (max-width: 768px) {
    .form-grid,
    .checkbox-grid {
        grid-template-columns: 1fr;
    }

    .security-row {
        flex-direction: column;
        align-items: stretch;
    }

    .security-row .checkbox-item {
        align-self: auto;
    }

    .sidebar {
        width: 280px;
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }

    body.lang-he .sidebar {
        transform: translateX(100%);
    }

    .sidebar.open {
        transform: translateX(0);
    }

    .main-content {
        margin-left: 0 !important;
        margin-right: 0 !important;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .page-header {
        flex-direction: column;
        gap: 15px;
        align-items: flex-start;
    }
}

/* ==================== ONBOARDING WIZARD ==================== */

.onboarding-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: #ffffff;
}

.onboarding-box {
    background: white;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    border: 1px solid #e9ecef;
    max-width: 600px;
    width: 100%;
    overflow: hidden;
}

.onboarding-header {
    background: #f8f9fa;
    color: #333;
    padding: 30px;
    text-align: center;
    border-bottom: 1px solid #eee;
}

.onboarding-header h1 {
    margin: 15px 0 10px;
    font-size: 24px;
}

.onboarding-steps {
    margin-top: 10px;
}

.step-indicator {
    background: #00876D;
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 14px;
}

.onboarding-step {
    padding: 40px;
    text-align: center;
}

.step-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: #e8f5f1;
    color: #00876D;
    border: 2px solid #00876D;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 36px;
}

.step-icon.success {
    background: #d4edda;
    color: #28a745;
    border-color: #28a745;
}

.onboarding-step h2 {
    color: #333;
    margin-bottom: 10px;
}

.onboarding-step p {
    color: #666;
    margin-bottom: 30px;
}

/* Number Display */
.number-display {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 30px;
}

.number-box {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 20px;
    border: 2px solid #e9ecef;
}

.number-box.highlight {
    background: linear-gradient(135deg, rgba(0, 135, 109, 0.1) 0%, rgba(0, 90, 71, 0.1) 100%);
    border-color: #00876D;
}

.number-box label {
    display: block;
    color: #666;
    font-size: 14px;
    margin-bottom: 10px;
}

.number-value {
    font-size: 28px;
    font-weight: 700;
    color: #00876D;
    font-family: 'Courier New', monospace;
    letter-spacing: 2px;
    direction: ltr;
}

.number-box small {
    display: block;
    margin-top: 10px;
    color: #888;
    font-size: 12px;
}

/* Phone Type Selector */
.phone-type-selector {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-bottom: 30px;
}

.phone-type-btn {
    width: 150px;
    height: 150px;
    border: 3px solid #e9ecef;
    border-radius: 20px;
    background: white;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 15px;
    transition: all 0.3s ease;
}

.phone-type-btn:hover {
    border-color: #00876D;
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 135, 109, 0.2);
}

.phone-type-btn i {
    font-size: 48px;
    color: #333;
}

.phone-type-btn span {
    font-size: 18px;
    font-weight: 600;
    color: #333;
}

/* Service Type Selector */
.service-type-selector {
    display: flex;
    flex-direction: column;
    gap: 15px;
    max-width: 450px;
    margin: 0 auto 30px;
}

.service-type-btn {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 20px 25px;
    border: 3px solid #e9ecef;
    border-radius: 16px;
    background: white;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: right;
    position: relative;
}

.service-type-btn:hover {
    border-color: var(--primary);
    transform: translateX(-5px);
    box-shadow: 0 8px 25px rgba(0, 135, 109, 0.15);
}

.service-type-btn.selected {
    border-color: var(--primary);
    background: linear-gradient(135deg, rgba(0,135,109,0.05) 0%, rgba(0,135,109,0.1) 100%);
}

.service-type-btn.selected .service-check {
    opacity: 1;
    transform: scale(1);
}

.service-icon {
    width: 60px;
    height: 60px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.service-icon i {
    font-size: 28px;
    color: white;
}

.service-icon.voicemail-icon {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.service-icon.ai-icon {
    background: linear-gradient(135deg, #00876D 0%, #00a884 100%);
}

.service-info {
    flex: 1;
}

.service-info h3 {
    margin: 0 0 5px 0;
    font-size: 18px;
    font-weight: 600;
    color: #333;
}

.service-info p {
    margin: 0;
    font-size: 14px;
    color: #666;
}

.service-check {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: var(--primary);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: scale(0.5);
    transition: all 0.3s ease;
}

.service-check i {
    font-size: 14px;
}

/* Instructions Box */
.instructions-box {
    text-align: right;
    background: #f8f9fa;
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 20px;
}

.instructions-box h3 {
    color: #333;
    margin-bottom: 20px;
    font-size: 18px;
}

.instruction-steps {
    margin-bottom: 20px;
}

.instruction-step {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 10px 0;
    border-bottom: 1px solid #e9ecef;
}

.instruction-step:last-child {
    border-bottom: none;
}

.step-num {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #00876D;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    flex-shrink: 0;
}

.forwarding-code {
    background: #f0f7f5;
    border-radius: 10px;
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    margin: 20px 0;
    border: 2px solid #00876D;
}

.forwarding-code code {
    font-size: 24px;
    font-weight: 700;
    color: #00876D;
    font-family: 'Courier New', monospace;
    letter-spacing: 2px;
    direction: ltr;
    background: transparent;
}

.instruction-note {
    background: #fff3cd;
    border-radius: 10px;
    padding: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
    color: #856404;
    font-size: 14px;
}

.instruction-note i {
    color: #ffc107;
    font-size: 18px;
}

/* Step Actions */
.step-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
}

/* Completion Summary */
.completion-summary {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 30px;
    text-align: right;
}

.summary-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 0;
    border-bottom: 1px solid #e9ecef;
}

.summary-item:last-child {
    border-bottom: none;
}

.summary-item i {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(0, 135, 109, 0.1);
    color: #00876D;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.summary-item span {
    color: #666;
    flex: 1;
}

.summary-item strong {
    color: #333;
    font-family: 'Courier New', monospace;
    direction: ltr;
}

/* Button variants */
.btn-lg {
    padding: 15px 40px;
    font-size: 18px;
}

.btn-link {
    background: none;
    border: none;
    color: #00876D;
    cursor: pointer;
    font-size: 14px;
}

.btn-link:hover {
    text-decoration: underline;
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
}

.btn-outline:hover {
    background: rgba(0, 135, 109, 0.1);
}

/* Responsive */
@media (max-width: 600px) {
    .phone-type-selector {
        flex-direction: column;
        align-items: center;
    }
    
    .phone-type-btn {
        width: 100%;
        max-width: 200px;
        height: 120px;
    }
    
    .forwarding-code {
        flex-direction: column;
    }
    
    .forwarding-code code {
        font-size: 18px;
    }
    
    .number-value {
        font-size: 22px;
    }
}

/* ===== Virtual Tour ===== */
.tour-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 9998;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: auto;
}

.tour-overlay.active {
    opacity: 1;
}

.tour-spotlight {
    position: fixed;
    z-index: 9999;
    border-radius: 8px;
    box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.6);
    transition: all 0.4s ease;
    pointer-events: none;
}

.tour-tooltip {
    position: fixed;
    z-index: 10000;
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 24px;
    width: 340px;
    max-width: 90vw;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.tour-tooltip.active {
    opacity: 1;
    transform: translateY(0);
}

.tour-tooltip-arrow {
    position: absolute;
    width: 12px;
    height: 12px;
    background: var(--white);
    transform: rotate(45deg);
    box-shadow: -2px -2px 4px rgba(0, 0, 0, 0.05);
}

.tour-tooltip-arrow.arrow-top {
    top: -6px;
    left: 50%;
    margin-left: -6px;
}

.tour-tooltip-arrow.arrow-bottom {
    bottom: -6px;
    left: 50%;
    margin-left: -6px;
    box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.05);
}

.tour-tooltip-arrow.arrow-left {
    left: -6px;
    top: 50%;
    margin-top: -6px;
}

.tour-tooltip-arrow.arrow-right {
    right: -6px;
    top: 50%;
    margin-top: -6px;
    box-shadow: 2px -2px 4px rgba(0, 0, 0, 0.05);
}

.tour-step-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--primary);
    color: var(--white);
    font-size: 12px;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 20px;
    margin-bottom: 10px;
}

.tour-tooltip h3 {
    font-size: 18px;
    font-weight: 700;
    color: var(--secondary);
    margin-bottom: 8px;
}

.tour-tooltip p {
    font-size: 14px;
    color: var(--gray-600);
    line-height: 1.7;
    margin-bottom: 16px;
}

.tour-progress {
    display: flex;
    gap: 4px;
    margin-bottom: 16px;
}

.tour-progress-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--gray-300);
    transition: background 0.3s ease;
}

.tour-progress-dot.active {
    background: var(--primary);
}

.tour-progress-dot.completed {
    background: var(--primary-light);
}

.tour-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
}

.tour-actions .btn {
    padding: 8px 16px;
    font-size: 14px;
    min-width: auto;
}

.tour-btn-skip {
    background: transparent;
    border: none;
    color: var(--gray-500);
    cursor: pointer;
    font-size: 13px;
    font-family: inherit;
    padding: 8px;
    transition: color 0.2s ease;
}

.tour-btn-skip:hover {
    color: var(--gray-700);
}

/* Tour welcome dialog */
.tour-welcome {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.tour-welcome.active {
    opacity: 1;
}

.tour-welcome-box {
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 40px;
    text-align: center;
    max-width: 400px;
    width: 90%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.tour-welcome.active .tour-welcome-box {
    transform: scale(1);
}

.tour-welcome-icon {
    font-size: 48px;
    color: var(--primary);
    margin-bottom: 16px;
}

.tour-welcome-box h2 {
    font-size: 22px;
    font-weight: 700;
    color: var(--secondary);
    margin-bottom: 12px;
}

.tour-welcome-box p {
    font-size: 15px;
    color: var(--gray-600);
    margin-bottom: 24px;
    line-height: 1.6;
}

.tour-welcome-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
}

.tour-welcome-actions .btn {
    min-width: 120px;
}

/* Tour start button in dashboard */
.btn-tour {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: var(--primary);
    color: var(--white);
    border: none;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: var(--transition);
}

.btn-tour:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 135, 109, 0.3);
}

.btn-tour i {
    font-size: 14px;
}

/* Tour video embed */
.tour-video {
    margin-bottom: 14px;
    border-radius: var(--radius);
    overflow: hidden;
    background: #000;
    position: relative;
}

.tour-video iframe {
    width: 100%;
    aspect-ratio: 16 / 9;
    border: none;
    display: block;
}

.tour-tooltip.has-video {
    width: 480px;
}

/* Responsive tour */
@media (max-width: 768px) {
    .tour-tooltip {
        width: 290px;
        padding: 18px;
    }

    .tour-tooltip.has-video {
        width: 90vw;
    }

    .tour-tooltip h3 {
        font-size: 16px;
    }

    .tour-tooltip p {
        font-size: 13px;
    }

    .tour-welcome-box {
        padding: 28px;
    }
}

/* My Package Features Section */
.feature-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: white;
    border-radius: 6px;
    font-size: 14px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.feature-item i {
    font-size: 16px;
    min-width: 20px;
}
