


.agent-profile-page {
    padding-top: 60px;
    min-height: 100vh;
    background: var(--bg-light);
}

.profile-header {
    background: linear-gradient(135deg, var(--primary-blue) 0%, #2d4a7c 100%);
    padding: 3rem 2rem;
}

.profile-header-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.profile-avatar-section {
    display: flex;
    gap: 1.5rem;
}

.profile-avatar {
    position: relative;
    width: 120px;
    height: 120px;
}

.profile-avatar img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid white;
}

.profile-avatar .verified-badge {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 32px;
    height: 32px;
    background: #059669;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 3px solid white;
}

.profile-info {
    color: white;
}

.profile-info h1 {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.profile-info .agency-name {
    font-size: 1rem;
    opacity: 0.9;
    margin-bottom: 0.25rem;
}

.profile-info .specialty {
    font-size: 0.9375rem;
    opacity: 0.8;
    margin-bottom: 0.75rem;
}

.profile-rating {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.profile-rating svg {
    color: var(--primary-gold);
}

.profile-rating span {
    font-weight: 600;
}

.profile-rating .review-count {
    opacity: 0.8;
    font-weight: 400;
}

.profile-languages {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.profile-languages span:first-child {
    opacity: 0.8;
}

.profile-languages .language-tag {
    background: rgba(255, 255, 255, 0.2);
    padding: 0.25rem 0.75rem;
    border-radius: var(--radius-sm);
    font-size: 0.8125rem;
}

.profile-actions {
    display: flex;
    gap: 0.75rem;
}

.btn-contact-primary {
    padding: 0.875rem 2rem;
    background: var(--primary-gold);
    color: var(--text-dark);
    border: none;
    border-radius: var(--radius-md);
    font-weight: 600;
    cursor: pointer;
}

.btn-share {
    width: 48px;
    height: 48px;
    background: rgba(255, 255, 255, 0.2);
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
}


.profile-stats {
    max-width: 1200px;
    margin: -2rem auto 0;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    position: relative;
    z-index: 10;
}

.profile-stats .stat-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    text-align: center;
    box-shadow: var(--shadow-md);
}

.profile-stats .stat-value {
    display: block;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-blue);
}

.profile-stats .stat-label {
    font-size: 0.8125rem;
    color: var(--text-gray);
}


.profile-content {
    max-width: 1200px;
    margin: 2rem auto 4rem;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 2rem;
}

.profile-main {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.profile-main .content-section {
    background: white;
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    border: 1px solid var(--border-color);
}

.profile-main .content-section h2 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--border-color);
}

.bio-text {
    color: var(--text-gray);
    line-height: 1.7;
}

.tags-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag {
    padding: 0.5rem 1rem;
    background: var(--bg-light);
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    color: var(--text-dark);
}

.tag.area {
    background: rgba(8, 49, 105, 0.1);
    color: var(--primary-blue);
}

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

.see-all {
    font-size: 0.875rem;
    color: var(--primary-blue);
    text-decoration: none;
}

.listings-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    margin-top: 1rem;
}

.listing-card {
    background: var(--bg-light);
    border-radius: var(--radius-md);
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    transition: transform 0.2s;
}

.listing-card:hover {
    transform: translateY(-2px);
}

.listing-card .listing-image {
    position: relative;
    height: 140px;
}

.listing-card .listing-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.listing-card .listing-badge {
    position: absolute;
    top: 0.5rem;
    left: 0.5rem;
    padding: 0.25rem 0.5rem;
    background: #dc2626;
    color: white;
    font-size: 0.6875rem;
    font-weight: 600;
    border-radius: var(--radius-sm);
}

.listing-card .listing-badge.rent { background: #059669; }
.listing-card .listing-badge.sold { background: #6b7280; }

.listing-card .listing-info {
    padding: 0.75rem;
}

.listing-card .listing-info h4 {
    font-size: 0.9375rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.listing-card .listing-price {
    font-weight: 700;
    color: var(--primary-blue);
    margin-bottom: 0.5rem;
}

.listing-card .listing-specs {
    display: flex;
    gap: 0.75rem;
    font-size: 0.75rem;
    color: var(--text-gray);
}


.btn-write-review {
    padding: 0.5rem 1rem;
    background: var(--primary-blue);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
}

.reviews-summary {
    display: flex;
    gap: 2rem;
    margin-bottom: 1.5rem;
    padding: 1.5rem;
    background: var(--bg-light);
    border-radius: var(--radius-md);
}

.rating-overview {
    text-align: center;
}

.big-rating {
    font-size: 3rem;
    font-weight: 700;
    color: var(--text-dark);
    line-height: 1;
}

.rating-stars {
    display: flex;
    gap: 0.25rem;
    justify-content: center;
    margin: 0.5rem 0;
    color: var(--primary-gold);
}

.total-reviews {
    font-size: 0.8125rem;
    color: var(--text-gray);
}

.rating-breakdown {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.rating-bar {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8125rem;
    color: var(--text-gray);
}

.rating-bar .bar {
    flex: 1;
    height: 8px;
    background: var(--border-color);
    border-radius: 4px;
    overflow: hidden;
}

.rating-bar .bar-fill {
    height: 100%;
    background: var(--primary-gold);
}

.reviews-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.review-card {
    padding: 1rem;
    background: var(--bg-light);
    border-radius: var(--radius-md);
}

.review-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.reviewer-avatar img {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
}

.reviewer-info {
    flex: 1;
}

.reviewer-info h4 {
    font-size: 0.9375rem;
    font-weight: 600;
}

.review-date {
    font-size: 0.8125rem;
    color: var(--text-gray);
}

.review-rating {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    color: var(--primary-gold);
    font-weight: 600;
}

.review-text {
    color: var(--text-gray);
    line-height: 1.6;
    margin-bottom: 0.5rem;
}

.transaction-type {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: rgba(8, 49, 105, 0.1);
    color: var(--primary-blue);
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 500;
}

.btn-load-more {
    width: 100%;
    padding: 0.75rem;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    cursor: pointer;
    font-weight: 500;
    margin-top: 1rem;
}


.profile-sidebar {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.profile-sidebar .contact-card,
.profile-sidebar .agency-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    border: 1px solid var(--border-color);
}

.profile-sidebar h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.profile-sidebar .contact-form {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.profile-sidebar .contact-form input,
.profile-sidebar .contact-form select,
.profile-sidebar .contact-form textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 0.9375rem;
}

.btn-send-message {
    width: 100%;
    padding: 0.875rem;
    background: var(--primary-blue);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    font-weight: 600;
    cursor: pointer;
}

.contact-direct {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
}

.contact-direct p {
    font-size: 0.8125rem;
    color: var(--text-gray);
    margin-bottom: 0.5rem;
}

.contact-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0;
    color: var(--primary-blue);
    text-decoration: none;
    font-size: 0.9375rem;
}

.agency-link {
    display: flex;
    align-items: center;
    gap: 1rem;
    text-decoration: none;
    color: inherit;
}

.agency-logo-placeholder {
    width: 60px;
    height: 60px;
    background: var(--bg-light);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-gray);
}

.agency-details h4 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.agency-details p {
    font-size: 0.8125rem;
    color: var(--primary-blue);
}


.watchlist-page {
    padding-top: 80px;
    min-height: 100vh;
    background: var(--bg-light);
    max-width: 1200px;
    margin: 0 auto;
    padding-left: 2rem;
    padding-right: 2rem;
    padding-bottom: 4rem;
}

.page-header {
    margin-bottom: 2rem;
}

.page-header h1 {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.page-header p {
    color: var(--text-gray);
}

.watchlist-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.watchlist-tabs .tab {
    padding: 0.625rem 1.25rem;
    border: 1px solid var(--border-color);
    background: white;
    border-radius: var(--radius-md);
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.2s;
}

.watchlist-tabs .tab.active {
    background: var(--primary-blue);
    color: white;
    border-color: var(--primary-blue);
}

.custom-lists {
    margin-bottom: 1.5rem;
}

.custom-lists h3 {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text-gray);
    margin-bottom: 0.75rem;
}

.lists-row {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.list-chip {
    padding: 0.5rem 1rem;
    border: 1px solid var(--border-color);
    background: white;
    border-radius: 50px;
    cursor: pointer;
    font-size: 0.8125rem;
    transition: all 0.2s;
}

.list-chip.selected {
    background: rgba(8, 49, 105, 0.1);
    border-color: var(--primary-blue);
    color: var(--primary-blue);
}

.list-chip.add-new {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--primary-blue);
    border-style: dashed;
}

.actions-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.left-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.selected-count {
    font-weight: 500;
    color: var(--text-dark);
}

.left-actions .btn-action {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border: 1px solid var(--border-color);
    background: white;
    border-radius: var(--radius-md);
    cursor: pointer;
    font-size: 0.875rem;
}

.left-actions .btn-action.danger {
    color: #dc2626;
    border-color: #dc2626;
}

.right-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.right-actions select {
    padding: 0.5rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 0.875rem;
}

.watchlist-card {
    position: relative;
    background: white;
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--border-color);
    transition: all 0.2s;
}

.watchlist-card.selected {
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 2px rgba(8, 49, 105, 0.2);
}

.watchlist-card .select-checkbox {
    position: absolute;
    top: 0.75rem;
    left: 0.75rem;
    z-index: 5;
}

.watchlist-card .select-checkbox input {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.watchlist-card .property-link {
    display: block;
    text-decoration: none;
    color: inherit;
}

.watchlist-card .property-image {
    position: relative;
    height: 180px;
}

.watchlist-card .property-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.watchlist-card .price-change {
    position: absolute;
    bottom: 0.5rem;
    left: 0.5rem;
    padding: 0.25rem 0.5rem;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 600;
}

.watchlist-card .price-change.down {
    background: #fee2e2;
    color: #dc2626;
}

.watchlist-card .price-change.up {
    background: #d1fae5;
    color: #059669;
}

.watchlist-card .property-info {
    padding: 1rem;
}

.watchlist-card .saved-date {
    font-size: 0.75rem;
    color: var(--text-light);
    margin-top: 0.5rem;
}

.watchlist-card .card-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
    padding: 0 1rem 1rem;
}

.empty-state {
    text-align: center;
    padding: 4rem 2rem;
    background: white;
    border-radius: var(--radius-lg);
}

.empty-state svg {
    color: var(--text-light);
    margin-bottom: 1rem;
}

.empty-state h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.empty-state p {
    color: var(--text-gray);
    margin-bottom: 1.5rem;
}

.compare-bar {
    position: fixed;
    bottom: 5rem;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary-blue);
    color: white;
    padding: 1rem 2rem;
    border-radius: 50px;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    box-shadow: var(--shadow-xl);
    z-index: 100;
}

.btn-compare {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1.25rem;
    background: white;
    color: var(--primary-blue);
    border: none;
    border-radius: var(--radius-md);
    font-weight: 600;
    cursor: pointer;
}



.leads-page {
}

.lead-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
}

.lead-stats .stat-box {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
}

.stat-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.stat-info {
    flex: 1;
}

.stat-info .stat-number {
    display: block;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-dark);
    line-height: 1;
    margin-bottom: 0.25rem;
}

.stat-info .stat-label {
    display: block;
    font-size: 0.875rem;
    color: var(--text-gray);
}


.leads-list-container {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.lead-card {
    background: white;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    padding: 1.5rem;
    display: grid;
    grid-template-columns: auto 1fr auto auto auto;
    gap: 1.5rem;
    align-items: center;
    transition: all 0.2s;
}

.lead-card.new {
    border-left: 4px solid var(--primary-blue);
    background: rgba(8, 49, 105, 0.02);
}

.lead-card:hover {
    box-shadow: var(--shadow-md);
}

.lead-main {
    display: flex;
    align-items: center;
    gap: 1rem;
    min-width: 280px;
}

.lead-avatar {
    position: relative;
}

.lead-avatar img {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    object-fit: cover;
}

.lead-avatar .new-badge {
    position: absolute;
    top: 0;
    right: 0;
    width: 12px;
    height: 12px;
    background: #dc2626;
    border: 2px solid white;
    border-radius: 50%;
}

.lead-info h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 0.25rem;
}

.lead-contact {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.8125rem;
    color: var(--text-gray);
    margin-bottom: 0.125rem;
}

.lead-contact:last-child {
    margin-bottom: 0;
}

.lead-property {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    min-width: 200px;
}

.property-label {
    font-size: 0.75rem;
    color: var(--text-light);
}

.property-link {
    color: var(--primary-blue);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.875rem;
}

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

.lead-message {
    flex: 1;
    max-width: 400px;
}

.lead-message p {
    font-size: 0.875rem;
    color: var(--text-gray);
    font-style: italic;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.lead-meta {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    align-items: flex-end;
}

.lead-source {
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
    background: var(--bg-light);
    border-radius: var(--radius-sm);
    color: var(--text-dark);
}

.lead-time {
    font-size: 0.75rem;
    color: var(--text-light);
}

.lead-status .status-badge {
    font-size: 0.75rem;
    padding: 0.375rem 0.75rem;
}

.lead-status .status-badge.new {
    background: rgba(8, 49, 105, 0.1);
    color: var(--primary-blue);
}

.lead-status .status-badge.contacted {
    background: rgba(212, 168, 83, 0.1);
    color: #d4a853;
}

.lead-status .status-badge.scheduled {
    background: rgba(124, 58, 237, 0.1);
    color: #7c3aed;
}

.lead-status .status-badge.qualified {
    background: rgba(5, 150, 105, 0.1);
    color: #059669;
}

.lead-actions {
    display: flex;
    gap: 0.375rem;
}

.btn-action {
    width: 36px;
    height: 36px;
    border: 1px solid var(--border-color);
    background: white;
    border-radius: var(--radius-md);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-gray);
    transition: all 0.2s;
}

.btn-action:hover {
    border-color: var(--primary-blue);
    color: var(--primary-blue);
}

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

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

.btn-action.success:hover {
    border-color: #059669;
    color: #059669;
}

.btn-action.danger:hover {
    border-color: #dc2626;
    color: #dc2626;
}


.showings-page {
}

.view-toggle {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
}

.view-toggle button {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1.25rem;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-gray);
    transition: all 0.2s;
}

.view-toggle button:hover {
    border-color: var(--primary-blue);
    color: var(--primary-blue);
}

.view-toggle button.active {
    background: var(--primary-blue);
    border-color: var(--primary-blue);
    color: white;
}


.calendar-container {
    background: white;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    overflow: hidden;
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.calendar-header h2 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-dark);
}

.btn-nav {
    width: 40px;
    height: 40px;
    background: none;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-gray);
    transition: all 0.2s;
}

.btn-nav:hover {
    border-color: var(--primary-blue);
    color: var(--primary-blue);
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
}

.calendar-day-header {
    padding: 1rem;
    text-align: center;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text-gray);
    text-transform: uppercase;
    background: var(--bg-light);
    border-bottom: 1px solid var(--border-color);
}

.calendar-day {
    min-height: 100px;
    padding: 0.5rem;
    border-bottom: 1px solid var(--border-color);
    border-right: 1px solid var(--border-color);
    background: white;
    cursor: pointer;
    transition: background 0.2s;
}

.calendar-day:hover {
    background: var(--bg-light);
}

.calendar-day:nth-child(7n) {
    border-right: none;
}

.calendar-day.other-month {
    background: var(--bg-light);
    color: var(--text-light);
}

.calendar-day.today {
    background: rgba(8, 49, 105, 0.05);
}

.calendar-day .day-number {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-dark);
}

.calendar-day.other-month .day-number {
    color: var(--text-light);
}

.calendar-day.today .day-number {
    color: var(--primary-blue);
}

.day-showings {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.showing-dot {
    font-size: 0.6875rem;
    padding: 0.125rem 0.375rem;
    border-radius: var(--radius-sm);
    text-align: center;
    font-weight: 500;
}

.showing-dot.scheduled {
    background: rgba(212, 168, 83, 0.15);
    color: #d4a853;
}

.showing-dot.confirmed {
    background: rgba(5, 150, 105, 0.15);
    color: #059669;
}

.showing-dot.completed {
    background: rgba(107, 114, 128, 0.15);
    color: #6b7280;
}

.more-count {
    font-size: 0.6875rem;
    color: var(--text-gray);
    text-align: center;
    margin-top: 0.25rem;
}


.showings-list-container {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.showing-group {
    background: white;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    padding: 1.5rem;
}

.group-date {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--border-color);
}

.showing-card {
    display: grid;
    grid-template-columns: 100px 1fr auto auto auto;
    gap: 1.5rem;
    align-items: center;
    padding: 1rem;
    border-radius: var(--radius-md);
    margin-bottom: 0.75rem;
    transition: all 0.2s;
}

.showing-card:last-child {
    margin-bottom: 0;
}

.showing-card:hover {
    background: var(--bg-light);
}

.showing-card.scheduled {
    border-left: 4px solid #d4a853;
}

.showing-card.confirmed {
    border-left: 4px solid #059669;
}

.showing-card.completed {
    border-left: 4px solid #6b7280;
}

.showing-time {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.showing-time .time {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-dark);
}

.showing-time .duration {
    font-size: 0.8125rem;
    color: var(--text-gray);
}

.showing-property {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.showing-property img {
    width: 80px;
    height: 60px;
    border-radius: var(--radius-sm);
    object-fit: cover;
}

.showing-property .property-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.showing-property .property-info a {
    font-weight: 500;
    color: var(--primary-blue);
    text-decoration: none;
    font-size: 0.9375rem;
}

.showing-property .property-info a:hover {
    text-decoration: underline;
}

.showing-property .property-price {
    font-size: 0.8125rem;
    color: var(--text-gray);
}

.showing-client {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.showing-client img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}

.showing-client .client-info {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.showing-client .client-name {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-dark);
}

.showing-client .client-phone {
    font-size: 0.75rem;
    color: var(--text-gray);
}


.analytics-page {
}

.period-select {
    padding: 0.625rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: white;
    font-size: 0.875rem;
    font-weight: 500;
}

.analytics-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
}

.analytics-stats .stat-card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
}

.stat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.stat-header .stat-label {
    font-size: 0.875rem;
    color: var(--text-gray);
}

.stat-header .stat-change {
    font-size: 0.75rem;
    font-weight: 600;
}

.stat-header .stat-change.positive {
    color: #059669;
}

.stat-header .stat-change.negative {
    color: #dc2626;
}

.analytics-stats .stat-value {
    display: block;
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 0.75rem;
}

.stat-chart.mini-chart {
    height: 40px;
}

.stat-chart.mini-chart svg {
    width: 100%;
    height: 100%;
}


.charts-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.chart-card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.chart-card.large {
    grid-column: span 2;
}

.chart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.chart-header h2 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-dark);
}

.chart-legend {
    display: flex;
    gap: 1.5rem;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8125rem;
    color: var(--text-gray);
}

.legend-item .dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.legend-item .dot.blue {
    background: #083169;
}

.legend-item .dot.gold {
    background: #d4a853;
}

.chart-legend.vertical {
    flex-direction: column;
    gap: 0.75rem;
}

.chart-body {
    padding: 1.5rem;
}

.chart-placeholder {
    width: 100%;
    min-height: 300px;
}


.top-listings {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.listing-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.listing-row img {
    width: 60px;
    height: 45px;
    border-radius: var(--radius-sm);
    object-fit: cover;
}

.listing-row .listing-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.listing-row .listing-address {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-dark);
}

.listing-row .listing-views {
    font-size: 0.75rem;
    color: var(--text-gray);
}

.listing-bar {
    flex: 1;
    max-width: 120px;
}

.listing-bar .bar {
    height: 8px;
    background: var(--bg-light);
    border-radius: 4px;
    overflow: hidden;
}

.listing-bar .bar-fill {
    height: 100%;
    background: var(--primary-blue);
}


.donut-chart {
    display: flex;
    justify-content: center;
    margin-bottom: 1.5rem;
}


.response-stats {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.response-metric {
    text-align: center;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.metric-value {
    display: block;
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-blue);
    margin-bottom: 0.25rem;
}

.metric-label {
    font-size: 0.875rem;
    color: var(--text-gray);
}

.response-breakdown {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.breakdown-item {
    display: grid;
    grid-template-columns: 80px 1fr 40px;
    gap: 0.75rem;
    align-items: center;
}

.breakdown-label {
    font-size: 0.8125rem;
    color: var(--text-dark);
}

.breakdown-bar {
    height: 8px;
    background: var(--bg-light);
    border-radius: 4px;
    overflow: hidden;
}

.breakdown-bar .bar-fill {
    height: 100%;
    background: var(--primary-blue);
}

.breakdown-bar .bar-fill.warning {
    background: #f59e0b;
}

.breakdown-value {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text-dark);
    text-align: right;
}


.bar-chart-horizontal {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.bar-row {
    display: grid;
    grid-template-columns: 80px 1fr 50px;
    gap: 0.75rem;
    align-items: center;
}

.bar-label {
    font-size: 0.8125rem;
    color: var(--text-dark);
    font-weight: 500;
}

.bar-container {
    height: 32px;
    background: var(--bg-light);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.bar-container .bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-blue), #5a8fd4);
}

.bar-value {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text-dark);
    text-align: right;
}


.transactions-page {
}

.transaction-summary {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
}

.summary-card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.summary-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.summary-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.summary-content .summary-label {
    font-size: 0.875rem;
    color: var(--text-gray);
}

.summary-content .summary-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-dark);
    line-height: 1;
}

.summary-content .summary-change,
.summary-content .summary-sub {
    font-size: 0.75rem;
    color: var(--text-gray);
}

.summary-content .summary-change.positive {
    color: #059669;
}


.transactions-table-container {
    background: white;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    overflow: hidden;
    margin-bottom: 1.5rem;
}

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

.transactions-table th,
.transactions-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.transactions-table th {
    background: var(--bg-light);
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-gray);
    text-transform: uppercase;
}

.transactions-table tbody tr {
    transition: background 0.2s;
}

.transactions-table tbody tr:hover {
    background: var(--bg-light);
}

.type-badge {
    display: inline-block;
    padding: 0.25rem 0.625rem;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 600;
}

.type-badge.sale {
    background: rgba(8, 49, 105, 0.1);
    color: var(--primary-blue);
}

.type-badge.rent {
    background: rgba(5, 150, 105, 0.1);
    color: #059669;
}

.client-cell {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.client-name {
    font-weight: 500;
    color: var(--text-dark);
}

.client-role {
    font-size: 0.75rem;
    color: var(--text-gray);
}

.commission-cell {
    font-weight: 600;
    color: #059669;
}

.date-cell {
    font-size: 0.875rem;
    color: var(--text-gray);
}

.status-badge.in-progress {
    background: rgba(212, 168, 83, 0.1);
    color: #d4a853;
}

.status-badge.closing {
    background: rgba(124, 58, 237, 0.1);
    color: #7c3aed;
}

.status-badge.closed {
    background: rgba(5, 150, 105, 0.1);
    color: #059669;
}

.status-badge.cancelled {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
}


@media (max-width: 1024px) {
    .lead-stats,
    .analytics-stats,
    .transaction-summary {
        grid-template-columns: repeat(2, 1fr);
    }

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

    .chart-card.large {
        grid-column: span 1;
    }

    .lead-card {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .showing-card {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
}

@media (max-width: 768px) {
    .lead-stats,
    .analytics-stats,
    .transaction-summary {
        grid-template-columns: 1fr;
    }

    .lead-card {
        padding: 1rem;
    }

    .lead-actions {
        width: 100%;
        justify-content: flex-start;
    }

    .calendar-day {
        min-height: 80px;
        padding: 0.25rem;
    }

    .calendar-day .day-number {
        font-size: 0.75rem;
    }

    .showing-dot {
        font-size: 0.625rem;
    }

    .transactions-table-container,
    .properties-table-container {
        overflow-x: auto;
    }
}



.subscription-page {
}

.subscription-page .page-header {
    margin-bottom: 2rem;
}

.subscription-page .page-header h1 {
    font-size: 1.75rem;
    font-weight: 700;
    margin: 0 0 0.5rem 0;
}

.subscription-page .page-header p {
    color: var(--text-gray);
    margin: 0;
}


.current-plan-section {
    margin-bottom: 3rem;
}

.current-plan-section h2 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
}

.current-plan-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 2rem;
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 2rem;
    align-items: start;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
    border: 2px solid transparent;
}

.current-plan-card.tier-basic {
    border-color: #64748B;
}

.current-plan-card.tier-professional {
    border-color: var(--primary-blue);
}

.current-plan-card.tier-enterprise {
    border-color: var(--primary-gold);
}

.plan-badge {
    padding: 0.5rem 1rem;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 0.875rem;
    text-transform: uppercase;
    background: linear-gradient(135deg, var(--primary-blue), var(--primary-gold));
    color: white;
}

.plan-details {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.plan-price {
    display: flex;
    align-items: baseline;
    gap: 0.25rem;
}

.plan-price .amount {
    font-size: 2.5rem;
    font-weight: 700;
}

.plan-price .period {
    color: var(--text-gray);
}

.plan-price .billing-type {
    font-size: 0.8125rem;
    color: var(--text-gray);
    margin-left: 0.5rem;
}

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

.info-row {
    display: flex;
    gap: 0.5rem;
    font-size: 0.9375rem;
}

.info-row .label {
    color: var(--text-gray);
}

.info-row .value {
    font-weight: 500;
}

.info-row .status-active {
    color: #16A34A;
}

.plan-features h4 {
    font-size: 0.9375rem;
    margin-bottom: 0.75rem;
}

.plan-features ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.plan-features li {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
}

.plan-features li svg {
    width: 16px;
    height: 16px;
    color: #16A34A;
    flex-shrink: 0;
}

.no-subscription {
    background: white;
    border-radius: var(--radius-lg);
    padding: 3rem;
    text-align: center;
}

.no-subscription svg {
    width: 64px;
    height: 64px;
    color: var(--text-gray);
    margin-bottom: 1rem;
}

.no-subscription h3 {
    margin-bottom: 0.5rem;
}

.no-subscription p {
    color: var(--text-gray);
}


.plans-section {
    margin-bottom: 3rem;
}

.plans-section h2 {
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
}

.billing-toggle {
    display: inline-flex;
    background: var(--bg-light);
    border-radius: var(--radius-md);
    padding: 4px;
    margin-bottom: 1.5rem;
}

.billing-toggle button {
    padding: 0.75rem 1.5rem;
    border: none;
    background: transparent;
    border-radius: var(--radius-sm);
    font-size: 0.9375rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.billing-toggle button.active {
    background: white;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.discount-badge {
    background: #DCFCE7;
    color: #16A34A;
    padding: 0.125rem 0.5rem;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 600;
}

.plans-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.plan-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 2rem;
    position: relative;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
    border: 2px solid transparent;
    transition: all 0.2s ease;
}

.plan-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.plan-card.popular {
    border-color: var(--primary-blue);
}

.plan-card.current {
    border-color: var(--primary-gold);
}

.popular-badge,
.current-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    padding: 0.25rem 1rem;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.popular-badge {
    background: var(--primary-blue);
    color: white;
}

.current-badge {
    background: var(--primary-gold);
    color: white;
}

.plan-header {
    margin-bottom: 1.5rem;
}

.plan-header h3 {
    font-size: 1.25rem;
    margin-bottom: 0.25rem;
}

.plan-description {
    font-size: 0.875rem;
    color: var(--text-gray);
    margin: 0;
}

.plan-pricing {
    margin-bottom: 1.5rem;
}

.plan-pricing .price {
    font-size: 2.5rem;
    font-weight: 700;
}

.plan-pricing .period {
    color: var(--text-gray);
}

.annual-total {
    font-size: 0.8125rem;
    color: var(--text-gray);
    margin-top: 0.25rem;
}

.plan-limits {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    padding: 0.75rem 0;
    margin-bottom: 0.75rem;
    border-bottom: 1px solid var(--border-light, #e2e8f0);
}

.plan-limits .limit-item {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--color-primary, #d4a03c);
}

.plan-features-list {
    list-style: none;
    padding: 0;
    margin: 0 0 1.5rem 0;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.plan-features-list li {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.875rem;
}

.plan-features-list li svg {
    width: 18px;
    height: 18px;
    color: #16A34A;
    flex-shrink: 0;
    margin-top: 2px;
}

.plan-action {
    margin-top: auto;
}

.plan-action .btn {
    width: 100%;
    justify-content: center;
}


.billing-section {
    margin-bottom: 3rem;
}

.billing-section .section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.billing-section h2 {
    font-size: 1.25rem;
    margin: 0;
}

.billing-table {
    background: white;
    border-radius: var(--radius-lg);
    overflow: hidden;
}

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

.billing-table th,
.billing-table td {
    padding: 1rem 1.5rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.billing-table th {
    background: var(--bg-light);
    font-weight: 600;
    font-size: 0.8125rem;
    text-transform: uppercase;
    color: var(--text-gray);
}

.billing-table td {
    font-size: 0.9375rem;
}

.billing-table .empty-row {
    text-align: center;
    color: var(--text-gray);
    padding: 2rem;
}

.status-badge {
    padding: 0.25rem 0.75rem;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 500;
}

.status-badge.paid {
    background: #DCFCE7;
    color: #16A34A;
}

.status-badge.pending {
    background: #FEF3C7;
    color: #D97706;
}

.status-badge.failed {
    background: #FEE2E2;
    color: #DC2626;
}


.danger-zone {
    background: #FEF2F2;
    border: 1px solid #FECACA;
    border-radius: var(--radius-lg);
    padding: 1.5rem;
}

.danger-zone h3 {
    color: #DC2626;
    margin-bottom: 0.5rem;
}

.danger-zone p {
    color: var(--text-gray);
    font-size: 0.9375rem;
    margin-bottom: 1rem;
}


.subscription-page .modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 1rem;
}

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

.subscription-page .modal-small {
    max-width: 400px;
}

.subscription-page .modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.subscription-page .modal-header h2 {
    font-size: 1.25rem;
    margin: 0;
}

.subscription-page .close-btn {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-md);
    border: none;
    background: transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.subscription-page .close-btn:hover {
    background: var(--bg-light);
}

.subscription-page .close-btn svg {
    width: 20px;
    height: 20px;
}

.subscription-page .modal-body {
    padding: 1.5rem;
}

.subscription-page .modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--border-color);
}

.change-summary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    padding: 1.5rem;
    background: var(--bg-light);
    border-radius: var(--radius-md);
    margin-bottom: 1.5rem;
}

.change-from,
.change-to {
    text-align: center;
}

.change-summary .label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-gray);
    text-transform: uppercase;
    margin-bottom: 0.25rem;
}

.change-summary .plan-name {
    font-size: 1.25rem;
    font-weight: 600;
}

.change-summary .arrow {
    width: 24px;
    height: 24px;
    color: var(--text-gray);
}

.pricing-breakdown {
    background: var(--bg-light);
    border-radius: var(--radius-md);
    padding: 1rem;
    margin-bottom: 1.5rem;
}

.breakdown-row {
    display: flex;
    justify-content: space-between;
    padding: 0.5rem 0;
    font-size: 0.9375rem;
}

.breakdown-row.credit {
    color: #16A34A;
}

.breakdown-row.total {
    border-top: 1px solid var(--border-color);
    margin-top: 0.5rem;
    padding-top: 0.75rem;
    font-weight: 600;
}

.downgrade-info {
    display: flex;
    gap: 1rem;
    padding: 1rem;
    background: #FEF3C7;
    border-radius: var(--radius-md);
    margin-bottom: 1.5rem;
}

.downgrade-info svg {
    width: 24px;
    height: 24px;
    color: #D97706;
    flex-shrink: 0;
}

.downgrade-info p {
    margin: 0;
    font-size: 0.9375rem;
    color: #92400E;
}

.subscribe-summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    background: var(--bg-light);
    border-radius: var(--radius-md);
    margin-bottom: 1.5rem;
}

.plan-preview h3 {
    margin: 0 0 0.25rem 0;
}

.plan-preview p {
    margin: 0;
    font-size: 0.875rem;
    color: var(--text-gray);
}

.price-preview .price {
    font-size: 1.5rem;
    font-weight: 700;
}

.price-preview .period {
    color: var(--text-gray);
}

.cancel-warning {
    text-align: center;
    padding: 1.5rem;
    background: #FEF2F2;
    border-radius: var(--radius-md);
    margin-bottom: 1.5rem;
}

.cancel-warning svg {
    width: 48px;
    height: 48px;
    color: #DC2626;
    margin-bottom: 1rem;
}

.cancel-warning h3 {
    color: #DC2626;
    margin-bottom: 0.5rem;
}

.cancel-warning p {
    margin: 0;
    color: var(--text-gray);
}

.subscription-page .form-group {
    margin-bottom: 1.25rem;
}

.subscription-page .form-group label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.subscription-page .form-group input,
.subscription-page .form-group textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 0.9375rem;
}

.subscription-page .form-group textarea {
    min-height: 100px;
    resize: vertical;
}

.subscription-page .checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.subscription-page .checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--primary-blue);
}

.subscription-page .error-message {
    padding: 0.75rem 1rem;
    background: #FEE2E2;
    color: #DC2626;
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    margin-top: 1rem;
}

.subscription-page .spinner-small {
    width: 16px;
    height: 16px;
    border: 2px solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
    margin-right: 0.5rem;
}


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

    .current-plan-card {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

@media (max-width: 768px) {
    .billing-table {
        overflow-x: auto;
    }

    .billing-table table {
        min-width: 600px;
    }
}



.profile-edit-layout {
    max-width: 960px;
    margin: 0 auto;
}

.profile-tabs {
    display: flex;
    gap: 0.25rem;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color, #e5e7eb);
    padding-bottom: 0;
}

.tab-btn {
    padding: 0.625rem 1.25rem;
    border: none;
    background: none;
    color: var(--text-secondary, #6b7280);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    transition: all 0.2s;
    margin-bottom: -1px;
}

.tab-btn:hover {
    color: var(--text-primary, #111827);
}

.tab-btn.active {
    color: var(--primary, #2563eb);
    border-bottom-color: var(--primary, #2563eb);
}

.form-card {
    background: var(--card-bg, #fff);
    border: 1px solid var(--border-color, #e5e7eb);
    border-radius: 0.75rem;
    padding: 1.5rem;
}

.form-card h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary, #111827);
    margin: 1.5rem 0 0.75rem 0;
}

.form-card h3:first-child {
    margin-top: 0;
}

.avatar-section {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color, #e5e7eb);
}

.avatar-preview {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
    background: var(--bg-secondary, #f3f4f6);
}

.avatar-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.avatar-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--primary, #2563eb);
    background: var(--primary-light, #dbeafe);
}

.avatar-actions {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

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

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
}

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

.form-group label {
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-secondary, #6b7280);
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 0.5rem 0.75rem;
    border: 1px solid var(--border-color, #e5e7eb);
    border-radius: 0.5rem;
    font-size: 0.875rem;
    font-family: inherit;
    background: var(--card-bg, #fff);
    color: var(--text-primary, #111827);
    transition: border-color 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary, #2563eb);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.form-group input:disabled {
    background: var(--bg-secondary, #f3f4f6);
    color: var(--text-tertiary, #9ca3af);
    cursor: not-allowed;
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.char-count {
    font-size: 0.75rem;
    color: var(--text-tertiary, #9ca3af);
    text-align: right;
}

.form-hint {
    font-size: 0.8125rem;
    color: var(--text-secondary, #6b7280);
    margin: 0.25rem 0 0 0;
    display: block;
}
.template-type-hint {
    color: var(--primary, #083169);
    font-weight: 600;
}

.form-actions {
    margin-top: 1.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--border-color, #e5e7eb);
    display: flex;
    justify-content: flex-end;
}

.success-banner {
    background: #ecfdf5;
    border: 1px solid #a7f3d0;
    color: #065f46;
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    margin-bottom: 1rem;
    font-size: 0.875rem;
}
.error-banner {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #991b1b;
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    margin-bottom: 1rem;
    font-size: 0.875rem;
}


.tags-input {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 0.5rem;
    border: 1px solid var(--border-color, #e5e7eb);
    border-radius: 0.5rem;
    margin-bottom: 1rem;
    min-height: 42px;
    align-items: center;
}

.tags-input input {
    border: none;
    outline: none;
    padding: 0.25rem;
    font-size: 0.875rem;
    flex: 1;
    min-width: 120px;
    background: transparent;
    color: var(--text-primary, #111827);
}

.tags-input .language-select {
    border: none;
    outline: none;
    padding: 0.25rem;
    font-size: 0.875rem;
    flex: 1;
    min-width: 140px;
    background: transparent;
    color: var(--text-secondary, #6b7280);
    cursor: pointer;
}

.tag {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.25rem 0.5rem;
    background: var(--primary-light, #dbeafe);
    color: var(--primary, #2563eb);
    border-radius: 1rem;
    font-size: 0.8125rem;
    font-weight: 500;
}

.tag button {
    background: none;
    border: none;
    color: inherit;
    cursor: pointer;
    padding: 0;
    font-size: 1rem;
    line-height: 1;
    opacity: 0.7;
}

.tag button:hover {
    opacity: 1;
}


.cert-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    border: 1px solid var(--border-color, #e5e7eb);
    border-radius: 0.5rem;
    margin-bottom: 0.5rem;
}

.cert-info {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.cert-info strong {
    font-size: 0.875rem;
    color: var(--text-primary, #111827);
}

.cert-info span {
    font-size: 0.8125rem;
    color: var(--text-secondary, #6b7280);
}

.cert-expiry {
    font-size: 0.75rem !important;
    color: var(--text-tertiary, #9ca3af) !important;
}


.inline-form {
    margin-top: 0.75rem;
    padding: 1rem;
    background: var(--bg-secondary, #f9fafb);
    border-radius: 0.5rem;
    border: 1px solid var(--border-color, #e5e7eb);
}

.inline-form-actions {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.75rem;
}


.social-link-row {
    display: grid;
    grid-template-columns: 140px 1fr auto;
    gap: 0.75rem;
    align-items: center;
    margin-bottom: 0.75rem;
}

.social-platform {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-primary, #111827);
}

.social-link-row input {
    padding: 0.5rem 0.75rem;
    border: 1px solid var(--border-color, #e5e7eb);
    border-radius: 0.5rem;
    font-size: 0.875rem;
}

.social-url-input {
    display: flex;
    align-items: center;
    border: 1px solid var(--border-color, #e5e7eb);
    border-radius: 0.5rem;
    overflow: hidden;
}

.social-base-url {
    padding: 0.5rem 0.5rem 0.5rem 0.75rem;
    font-size: 0.8rem;
    color: var(--text-secondary, #6b7280);
    background: var(--bg-secondary, #f9fafb);
    white-space: nowrap;
    border-right: 1px solid var(--border-color, #e5e7eb);
}

.social-url-input input {
    flex: 1;
    border: none !important;
    border-radius: 0 !important;
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
    min-width: 0;
}

.social-url-input input:focus {
    outline: none;
    box-shadow: none;
}

.add-social-row {
    display: grid;
    grid-template-columns: 180px 1fr auto;
    gap: 0.75rem;
    align-items: center;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color, #e5e7eb);
}

.add-social-row select,
.add-social-row input {
    padding: 0.5rem 0.75rem;
    border: 1px solid var(--border-color, #e5e7eb);
    border-radius: 0.5rem;
    font-size: 0.875rem;
}


.btn-outline {
    padding: 0.5rem 1rem;
    border: 1px solid var(--border-color, #e5e7eb);
    background: var(--card-bg, #fff);
    border-radius: 0.5rem;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-primary, #111827);
    cursor: pointer;
    transition: all 0.2s;
}

.btn-outline:hover {
    background: var(--bg-secondary, #f3f4f6);
}

.btn-text-danger {
    background: none;
    border: none;
    color: #ef4444;
    font-size: 0.8125rem;
    cursor: pointer;
    padding: 0.25rem 0.5rem;
}

.btn-text-danger:hover {
    color: #dc2626;
    text-decoration: underline;
}


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

    .avatar-section {
        flex-direction: column;
        text-align: center;
    }

    .social-link-row,
    .add-social-row {
        grid-template-columns: 1fr;
    }

    .profile-tabs {
        overflow-x: auto;
    }
}



.notifications-layout {
    max-width: 800px;
}

.notification-filters {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.filter-chip {
    padding: 0.375rem 0.75rem;
    border: 1px solid var(--border-color, #e5e7eb);
    background: var(--card-bg, #fff);
    border-radius: 2rem;
    font-size: 0.8125rem;
    cursor: pointer;
    color: var(--text-secondary, #6b7280);
    transition: all 0.2s;
}

.filter-chip:hover {
    border-color: var(--primary, #2563eb);
}

.filter-chip.active {
    background: var(--primary, #2563eb);
    color: #fff;
    border-color: var(--primary, #2563eb);
}

.filter-chip .count {
    font-weight: 600;
    margin-left: 0.25rem;
}

.notification-list {
    display: flex;
    flex-direction: column;
    border: 1px solid var(--border-color, #e5e7eb);
    border-radius: 0.75rem;
    overflow: hidden;
}

.notification-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem;
    background: var(--card-bg, #fff);
    border-bottom: 1px solid var(--border-color, #e5e7eb);
    cursor: pointer;
    transition: background 0.15s;
}

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

.notification-item:hover {
    background: var(--bg-secondary, #f9fafb);
}

.notification-item.unread {
    background: #f0f7ff;
}

.notification-item.unread:hover {
    background: #e8f2ff;
}

.notification-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-weight: 700;
    font-size: 0.875rem;
}

.notification-icon.type-info {
    background: #dbeafe;
    color: #2563eb;
}

.notification-icon.type-price {
    background: #d1fae5;
    color: #059669;
}

.notification-icon.type-status {
    background: #fef3c7;
    color: #d97706;
}

.notification-icon.type-match {
    background: #ede9fe;
    color: #7c3aed;
}

.notification-icon.type-system {
    background: #fee2e2;
    color: #dc2626;
}

.notification-body {
    flex: 1;
    min-width: 0;
}

.notification-title {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary, #111827);
    margin-bottom: 0.125rem;
}

.notification-message {
    font-size: 0.8125rem;
    color: var(--text-secondary, #6b7280);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.notification-time {
    font-size: 0.75rem;
    color: var(--text-tertiary, #9ca3af);
    margin-top: 0.25rem;
}

.unread-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--primary, #2563eb);
    flex-shrink: 0;
    margin-top: 0.375rem;
}

.load-more {
    text-align: center;
    margin-top: 1rem;
}


.notification-preferences {
    margin-top: 2rem;
    background: var(--card-bg, #fff);
    border: 1px solid var(--border-color, #e5e7eb);
    border-radius: 0.75rem;
    padding: 1.5rem;
}

.notification-preferences h3 {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 1rem 0;
}

.pref-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

.pref-toggle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    font-size: 0.875rem;
    color: var(--text-primary, #111827);
}

.pref-toggle input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--primary, #2563eb);
}

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


[data-theme="dark"] .agent-layout {
    background: #111827;
}

[data-theme="dark"] .agent-sidebar {
    background: #1e293b;
    border-right-color: #334155;
}

[data-theme="dark"] .sidebar-header {
    border-bottom-color: #334155;
}

[data-theme="dark"] .sidebar-logo {
    color: #e2e8f0;
}

[data-theme="dark"] .agent-sidebar .sidebar-toggle {
    color: #94a3b8;
}

[data-theme="dark"] .agent-sidebar .sidebar-toggle:hover {
    background: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .sidebar-nav .nav-item {
    color: #94a3b8;
}

[data-theme="dark"] .sidebar-nav .nav-item:hover {
    color: #e2e8f0;
    background: #334155;
}

[data-theme="dark"] .sidebar-nav .nav-item.active {
    color: white;
    background: #D4A03C;
}

[data-theme="dark"] .nav-divider {
    background: #334155;
}

[data-theme="dark"] .agent-topbar {
    background: #1e293b;
    border-bottom-color: #334155;
}

[data-theme="dark"] .topbar-search {
    background: #0f172a;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .topbar-search input {
    background: transparent;
    color: #e2e8f0;
}

[data-theme="dark"] .topbar-search input::placeholder {
    color: #64748b;
}

[data-theme="dark"] .topbar-search svg {
    color: #64748b;
}

[data-theme="dark"] .topbar-btn {
    color: #94a3b8;
    border-color: #334155;
}

[data-theme="dark"] .topbar-btn:hover {
    background: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .user-menu {
    border-color: #334155;
}

[data-theme="dark"] .user-menu:hover {
    border-color: #475569;
}

[data-theme="dark"] .user-name {
    color: #e2e8f0;
}

[data-theme="dark"] .agent-content {
    background: #111827;
}

[data-theme="dark"] .sidebar-overlay {
    background: rgba(0,0,0,0.6);
}


[data-theme="dark"] .stat-card,
[data-theme="dark"] .dash-card,
[data-theme="dark"] .analytics-card,
[data-theme="dark"] .chart-card {
    background: #1e293b;
    border-color: #334155;
}

[data-theme="dark"] .stat-card h3,
[data-theme="dark"] .dash-card h3,
[data-theme="dark"] .card-title {
    color: #e2e8f0;
}

[data-theme="dark"] .stat-card .stat-label,
[data-theme="dark"] .stat-card p {
    color: #94a3b8;
}

[data-theme="dark"] .stat-card .stat-value {
    color: #e2e8f0;
}


[data-theme="dark"] .data-table,
[data-theme="dark"] table {
    border-color: #334155;
}

[data-theme="dark"] .data-table th,
[data-theme="dark"] table th {
    background: #0f172a;
    color: #94a3b8;
    border-bottom-color: #334155;
}

[data-theme="dark"] .data-table td,
[data-theme="dark"] table td {
    border-bottom-color: #1e293b;
    color: #e2e8f0;
}

[data-theme="dark"] .data-table tr:hover td,
[data-theme="dark"] table tbody tr:hover {
    background: #334155;
}


[data-theme="dark"] input[type="text"],
[data-theme="dark"] input[type="email"],
[data-theme="dark"] input[type="password"],
[data-theme="dark"] input[type="number"],
[data-theme="dark"] input[type="tel"],
[data-theme="dark"] input[type="url"],
[data-theme="dark"] input[type="search"],
[data-theme="dark"] input[type="date"],
[data-theme="dark"] textarea,
[data-theme="dark"] select,
[data-theme="dark"] .form-control,
[data-theme="dark"] .form-select {
    background: #0f172a;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] input::placeholder,
[data-theme="dark"] textarea::placeholder {
    color: #64748b;
}

[data-theme="dark"] input:focus,
[data-theme="dark"] textarea:focus,
[data-theme="dark"] select:focus,
[data-theme="dark"] .form-control:focus {
    border-color: #4a7ab5;
    box-shadow: 0 0 0 3px rgba(74, 122, 181, 0.15);
}

[data-theme="dark"] label {
    color: #cbd5e1;
}


[data-theme="dark"] .btn-secondary,
[data-theme="dark"] .btn-outline {
    background: #1e293b;
    border-color: #475569;
    color: #e2e8f0;
}

[data-theme="dark"] .btn-secondary:hover,
[data-theme="dark"] .btn-outline:hover {
    background: #334155;
    border-color: #64748b;
}


[data-theme="dark"] .modal-content,
[data-theme="dark"] .dialog-content {
    background: #1e293b;
    border-color: #334155;
}

[data-theme="dark"] .modal-header,
[data-theme="dark"] .dialog-header {
    border-bottom-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .modal-footer,
[data-theme="dark"] .dialog-footer {
    border-top-color: #334155;
}


[data-theme="dark"] .pagination .page-link {
    background: #1e293b;
    border-color: #334155;
    color: #94a3b8;
}

[data-theme="dark"] .pagination .page-link:hover {
    background: #334155;
    color: #e2e8f0;
}


[data-theme="dark"] .notification-badge {
    border-color: #1e293b;
}


[data-theme="dark"] ::-webkit-scrollbar-track {
    background: #0f172a;
}

[data-theme="dark"] ::-webkit-scrollbar-thumb {
    background: #334155;
}

[data-theme="dark"] ::-webkit-scrollbar-thumb:hover {
    background: #475569;
}


[data-theme="dark"] .dashboard-card,
[data-theme="dark"] .action-card,
[data-theme="dark"] .empty-state {
    background: #1e293b;
    border-color: #334155;
}

[data-theme="dark"] .action-card {
    color: #e2e8f0;
}

[data-theme="dark"] .card-header {
    border-bottom-color: #334155;
}

[data-theme="dark"] .card-header h2 {
    color: #e2e8f0;
}

[data-theme="dark"] .activity-item .activity-text,
[data-theme="dark"] .showing-item .showing-address {
    color: #e2e8f0;
}

[data-theme="dark"] .activity-item .activity-time,
[data-theme="dark"] .showing-item .showing-time {
    color: #64748b;
}


[data-theme="dark"] .profile-stats .stat-card,
[data-theme="dark"] .profile-main .content-section,
[data-theme="dark"] .profile-sidebar .contact-card,
[data-theme="dark"] .profile-sidebar .agency-card {
    background: #1e293b;
    border-color: #334155;
}

[data-theme="dark"] .profile-main .content-section h2 {
    color: #e2e8f0;
    border-bottom-color: #334155;
}

[data-theme="dark"] .btn-load-more {
    background: #1e293b;
    border-color: #334155;
    color: #94a3b8;
}


[data-theme="dark"] .watchlist-tabs .tab,
[data-theme="dark"] .list-chip,
[data-theme="dark"] .watchlist-card {
    background: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .watchlist-tabs .tab.active {
    background: #334155;
    color: #e2e8f0;
}


[data-theme="dark"] .page-actions .filter-btn,
[data-theme="dark"] .page-actions .btn-secondary,
[data-theme="dark"] .stat-box,
[data-theme="dark"] .properties-table-container,
[data-theme="dark"] .dropdown-menu {
    background: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .filter-btn,
[data-theme="dark"] .sort-select {
    background: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .stat-box .stat-value {
    color: #e2e8f0;
}

[data-theme="dark"] .stat-box .stat-label {
    color: #94a3b8;
}

[data-theme="dark"] .properties-table-container th {
    background: #0f172a;
    color: #94a3b8;
    border-bottom-color: #334155;
}

[data-theme="dark"] .properties-table-container td {
    border-bottom-color: #1e293b;
    color: #e2e8f0;
}

[data-theme="dark"] .properties-table-container tr:hover td {
    background: #334155;
}

[data-theme="dark"] .dropdown-menu {
    box-shadow: 0 4px 20px rgba(0,0,0,0.4);
}


[data-theme="dark"] .add-property-page {
    color: #e2e8f0;
}

[data-theme="dark"] .property-form,
[data-theme="dark"] .form-actions .btn-secondary {
    background: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .property-form h2,
[data-theme="dark"] .property-form h3 {
    color: #e2e8f0;
}

[data-theme="dark"] .form-progress {
    background: #1e293b;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

[data-theme="dark"] .step-number {
    background: #1e293b;
    border-color: #475569;
    color: #94a3b8;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

[data-theme="dark"] .step-label {
    color: #94a3b8;
}

[data-theme="dark"] .progress-line {
    background: linear-gradient(90deg, #334155, #334155);
}

[data-theme="dark"] .add-property-page .page-header-section {
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.15);
}

[data-theme="dark"] .form-section {
    background: #1e293b;
    border-bottom-color: #334155;
}

[data-theme="dark"] .form-group label {
    color: #cbd5e1;
}

[data-theme="dark"] .form-group input,
[data-theme="dark"] .form-group select,
[data-theme="dark"] .form-group textarea {
    background: #0f172a;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .form-group input::placeholder,
[data-theme="dark"] .form-group textarea::placeholder {
    color: #64748b;
}

[data-theme="dark"] .form-group input:focus,
[data-theme="dark"] .form-group select:focus,
[data-theme="dark"] .form-group textarea:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102,126,234,0.15);
}

[data-theme="dark"] .form-actions {
    background: #1e293b;
    border-top-color: #334155;
}

[data-theme="dark"] .image-upload-area {
    background: #0f172a;
    border-color: #334155;
    color: #94a3b8;
}

[data-theme="dark"] .image-upload-area:hover {
    border-color: #667eea;
    background: rgba(102,126,234,0.05);
}

[data-theme="dark"] .input-with-prefix .prefix {
    color: #64748b;
}

[data-theme="dark"] .char-count {
    color: #64748b;
}

[data-theme="dark"] .details-subsection {
    background: #0f172a;
    border-color: #334155;
}

[data-theme="dark"] .subsection-header {
    border-bottom-color: #334155;
}

[data-theme="dark"] .subsection-header h3 {
    color: #e2e8f0;
}

[data-theme="dark"] .feature-checkbox {
    border-color: #334155;
    color: #cbd5e1;
}

[data-theme="dark"] .feature-checkbox:has(input:checked) {
    background: rgba(102,126,234,0.1);
    border-color: #667eea;
}

[data-theme="dark"] .feature-checkbox span {
    color: #cbd5e1;
}

[data-theme="dark"] .step-btn {
    background: #1e293b;
    border-color: #334155;
    color: #94a3b8;
}

[data-theme="dark"] .step-btn.active {
    color: #e2e8f0;
}

[data-theme="dark"] .upload-section {
    border-top-color: #334155;
}

[data-theme="dark"] .upload-zone {
    border-color: rgba(102, 126, 234, 0.25);
    background: linear-gradient(to bottom, rgba(102, 126, 234, 0.04), rgba(118, 75, 162, 0.04));
}

[data-theme="dark"] .upload-zone:hover {
    background: linear-gradient(to bottom, rgba(102, 126, 234, 0.08), rgba(118, 75, 162, 0.08));
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.2);
}

[data-theme="dark"] .map-picker {
    border-color: #334155;
}

[data-theme="dark"] .coords-display {
    background: rgba(5, 150, 105, 0.1);
    color: #34d399;
}

[data-theme="dark"] .btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}


[data-theme="dark"] .view-toggle button {
    background: #1e293b;
    border-color: #334155;
    color: #94a3b8;
}
[data-theme="dark"] .view-toggle button:hover {
    border-color: #667eea;
    color: #667eea;
}
[data-theme="dark"] .calendar-day {
    background: #1e293b;
    border-color: #334155;
}
[data-theme="dark"] .calendar-day:hover {
    background: #334155;
}
[data-theme="dark"] .calendar-day.other-month {
    background: #0f172a;
}
[data-theme="dark"] .calendar-day.today {
    background: rgba(102,126,234,0.1);
}
[data-theme="dark"] .calendar-day .day-number {
    color: #e2e8f0;
}
[data-theme="dark"] .calendar-day.other-month .day-number {
    color: #475569;
}
[data-theme="dark"] .calendar-day-header {
    background: #0f172a;
    border-color: #334155;
    color: #94a3b8;
}
[data-theme="dark"] .showing-card:hover {
    background: #334155;
}


[data-theme="dark"] .profile-tabs {
    border-bottom-color: #334155;
}
[data-theme="dark"] .tab-btn {
    color: #94a3b8;
}
[data-theme="dark"] .tab-btn:hover {
    color: #e2e8f0;
}
[data-theme="dark"] .tab-btn.active {
    color: #818cf8;
    border-bottom-color: #818cf8;
}
[data-theme="dark"] .form-card {
    background: #1e293b;
    border-color: #334155;
}
[data-theme="dark"] .form-card h3 {
    color: #e2e8f0;
}
[data-theme="dark"] .avatar-section {
    border-bottom-color: #334155;
}
[data-theme="dark"] .avatar-preview {
    background: #334155;
}
[data-theme="dark"] .avatar-placeholder {
    background: rgba(99, 102, 241, 0.15);
    color: #818cf8;
}
[data-theme="dark"] .form-group label {
    color: #94a3b8;
}
[data-theme="dark"] .form-group input,
[data-theme="dark"] .form-group select,
[data-theme="dark"] .form-group textarea {
    background: #0f172a;
    color: #e2e8f0;
    border-color: #334155;
}
[data-theme="dark"] .form-group input:disabled {
    background: #1e293b;
    color: #64748b;
}
[data-theme="dark"] .form-actions {
    border-top-color: #334155;
}
[data-theme="dark"] .success-banner {
    background: rgba(16, 185, 129, 0.1);
    border-color: rgba(16, 185, 129, 0.3);
    color: #34d399;
}
[data-theme="dark"] .error-banner {
    background: rgba(220, 38, 38, 0.1);
    border-color: rgba(220, 38, 38, 0.3);
    color: #f87171;
}
[data-theme="dark"] .tags-input {
    border-color: #334155;
    background: #0f172a;
}
[data-theme="dark"] .tags-input input {
    color: #e2e8f0;
    background: transparent;
}
[data-theme="dark"] .tags-input .language-select {
    color: #94a3b8;
    background: transparent;
}
[data-theme="dark"] .tag {
    background: #334155;
    color: #e2e8f0;
}
[data-theme="dark"] .cert-card {
    background: #0f172a;
    border-color: #334155;
}
[data-theme="dark"] .cert-card strong {
    color: #e2e8f0;
}
[data-theme="dark"] .cert-expiry {
    color: #94a3b8;
}
[data-theme="dark"] .social-link-row {
    border-color: #334155;
}
[data-theme="dark"] .social-link-row input {
    background: #0f172a;
    color: #e2e8f0;
    border-color: #334155;
}
[data-theme="dark"] .social-platform {
    color: #e2e8f0;
}
[data-theme="dark"] .social-url-input {
    border-color: #334155;
}
[data-theme="dark"] .social-base-url {
    background: #1e293b;
    color: #94a3b8;
    border-color: #334155;
}
[data-theme="dark"] .social-url-input input {
    background: #0f172a;
    color: #e2e8f0;
}
[data-theme="dark"] .add-social-row select {
    background: #0f172a;
    color: #e2e8f0;
    border-color: #334155;
}
[data-theme="dark"] .inline-form {
    background: #0f172a;
    border-color: #334155;
}
[data-theme="dark"] .form-hint {
    color: #64748b;
}


[data-theme="dark"] .lead-search,
[data-theme="dark"] .lead-card,
[data-theme="dark"] .leads-table,
[data-theme="dark"] .leads-filter-btn {
    background: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .lead-card h3 {
    color: #e2e8f0;
}

[data-theme="dark"] .leads-row {
    border-bottom-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .leads-row:hover {
    background: #334155;
}

[data-theme="dark"] .leads-header {
    background: #0f172a;
    color: #94a3b8;
}


[data-theme="dark"] .showing-filter-btn,
[data-theme="dark"] .calendar-container,
[data-theme="dark"] .showing-group,
[data-theme="dark"] .day-detail-panel {
    background: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .calendar-cell {
    background: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .calendar-cell:hover {
    background: #334155;
}

[data-theme="dark"] .calendar-cell.today {
    background: #0f172a;
}

[data-theme="dark"] .calendar-header-cell {
    color: #94a3b8;
}

[data-theme="dark"] .showing-group h3,
[data-theme="dark"] .day-detail-panel h3 {
    color: #e2e8f0;
}


[data-theme="dark"] .analytics-stats .stat-card,
[data-theme="dark"] .chart-card {
    background: #1e293b;
    border-color: #334155;
}

[data-theme="dark"] .chart-card h3 {
    color: #e2e8f0;
}


[data-theme="dark"] .summary-card,
[data-theme="dark"] .transactions-table-container {
    background: #1e293b;
    border-color: #334155;
}

[data-theme="dark"] .summary-card h3 {
    color: #e2e8f0;
}

[data-theme="dark"] .summary-card .value {
    color: #e2e8f0;
}

[data-theme="dark"] .transactions-table-container th {
    background: #0f172a;
    color: #94a3b8;
    border-bottom-color: #334155;
}

[data-theme="dark"] .transactions-table-container td {
    border-bottom-color: #1e293b;
    color: #e2e8f0;
}

[data-theme="dark"] .transactions-table-container tr:hover td {
    background: #334155;
}


[data-theme="dark"] .method-card,
[data-theme="dark"] .csv-upload-area,
[data-theme="dark"] .manual-entry-area,
[data-theme="dark"] .review-section,
[data-theme="dark"] .complete-section {
    background: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .method-card h3 {
    color: #e2e8f0;
}


[data-theme="dark"] .team-page .stat-card,
[data-theme="dark"] .member-card,
[data-theme="dark"] .team-page .access-denied,
[data-theme="dark"] .team-page .empty-state,
[data-theme="dark"] .team-page .modal,
[data-theme="dark"] .team-tab.active,
[data-theme="dark"] .team-listing-card,
[data-theme="dark"] .team-filter-select {
    background: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .member-card h3 {
    color: #e2e8f0;
}

[data-theme="dark"] .team-tab {
    color: #94a3b8;
}


[data-theme="dark"] .current-plan-card,
[data-theme="dark"] .no-subscription,
[data-theme="dark"] .plan-card,
[data-theme="dark"] .billing-table,
[data-theme="dark"] .subscription-page .modal {
    background: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .billing-toggle button.active {
    background: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .plan-card h3,
[data-theme="dark"] .plan-card .price {
    color: #e2e8f0;
}

[data-theme="dark"] .billing-table th {
    background: #0f172a;
    color: #94a3b8;
    border-bottom-color: #334155;
}

[data-theme="dark"] .billing-table td {
    border-bottom-color: #1e293b;
    color: #e2e8f0;
}


[data-theme="dark"] .marketing-page .filters-bar select,
[data-theme="dark"] .material-card,
[data-theme="dark"] .template-card,
[data-theme="dark"] .btn-nav,
[data-theme="dark"] .marketing-page .modal-content {
    background: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .material-info h3,
[data-theme="dark"] .template-info h4 {
    color: #e2e8f0;
}

[data-theme="dark"] .material-actions {
    border-top-color: #334155;
}

[data-theme="dark"] .btn-sm.btn-outline {
    background: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .marketing-page .modal-header {
    border-bottom-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .marketing-page .modal-footer {
    border-top-color: #334155;
}

[data-theme="dark"] .thumbnail-placeholder {
    background: linear-gradient(135deg, #1e293b, #334155);
    color: #64748b;
}


[data-theme="dark"] .publish-tabs {
    border-bottom-color: #334155;
}

[data-theme="dark"] .publish-tab {
    color: #94a3b8;
}

[data-theme="dark"] .publish-tab:hover,
[data-theme="dark"] .publish-tab.active {
    color: #e2e8f0;
}

[data-theme="dark"] .publish-tab.active {
    border-bottom-color: #e2e8f0;
}

[data-theme="dark"] .share-url-box input,
[data-theme="dark"] .social-caption,
[data-theme="dark"] .contact-search,
[data-theme="dark"] .manual-email-row input {
    background: #0f172a;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .publish-stats-row {
    border-top-color: #334155;
}

[data-theme="dark"] .publish-stat-value {
    color: #e2e8f0;
}

[data-theme="dark"] .publish-stat-label {
    color: #64748b;
}

[data-theme="dark"] .contact-list {
    border-color: #334155;
}

[data-theme="dark"] .contact-item {
    border-bottom-color: #334155;
}

[data-theme="dark"] .contact-item:hover {
    background: #334155;
}

[data-theme="dark"] .contact-name {
    color: #e2e8f0;
}

[data-theme="dark"] .contact-email {
    color: #64748b;
}

[data-theme="dark"] .contact-list-header label,
[data-theme="dark"] .social-caption-section label {
    color: #cbd5e1;
}

[data-theme="dark"] .publish-hint {
    color: #64748b;
}

[data-theme="dark"] .email-tag {
    background: rgba(8,49,105,0.3);
    color: #93c5fd;
}

[data-theme="dark"] .publish-message.success {
    background: rgba(6,95,70,0.2);
    color: #6ee7b7;
    border-color: rgba(6,95,70,0.3);
}

[data-theme="dark"] .publish-message.error {
    background: rgba(153,27,27,0.2);
    color: #fca5a5;
    border-color: rgba(153,27,27,0.3);
}


[data-theme="dark"] .status-draft { background: #334155; color: #94a3b8; }
[data-theme="dark"] .status-generating { background: rgba(217,119,6,0.2); color: #fbbf24; }
[data-theme="dark"] .status-ready { background: rgba(22,163,106,0.2); color: #4ade80; }
[data-theme="dark"] .status-archived { background: #334155; color: #64748b; }


[data-theme="dark"] .profile-edit-container,
[data-theme="dark"] .profile-edit-section {
    background: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .profile-edit-section h2 {
    color: #e2e8f0;
    border-bottom-color: #334155;
}


[data-theme="dark"] .notification-card,
[data-theme="dark"] .notification-item {
    background: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .notification-item:hover {
    background: #334155;
}


[data-theme="dark"] .event-type-badge.openhouse {
    background: rgba(217,119,6,0.2);
    color: #fbbf24;
}


[data-theme="dark"] .calendar-header-bar h3,
[data-theme="dark"] .day-detail-header h4,
[data-theme="dark"] .event-card-content h5 {
    color: #e2e8f0;
}

[data-theme="dark"] .calendar-weekdays {
    color: #64748b;
    border-bottom-color: #334155;
}

[data-theme="dark"] .calendar-month-grid {
    background: #334155;
    border-color: #334155;
}

[data-theme="dark"] .calendar-cell.empty {
    background: #0f172a;
}

[data-theme="dark"] .calendar-cell.today {
    background: rgba(59,130,246,0.1);
}

[data-theme="dark"] .calendar-cell.selected {
    background: rgba(59,130,246,0.15);
}

[data-theme="dark"] .cell-day-num {
    color: #cbd5e1;
}

[data-theme="dark"] .day-detail-header {
    border-bottom-color: #334155;
    background: #0f172a;
}

[data-theme="dark"] .event-count {
    background: #334155;
    color: #94a3b8;
}

[data-theme="dark"] .close-btn-sm {
    color: #64748b;
}

[data-theme="dark"] .close-btn-sm:hover {
    background: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .day-event-card {
    background: #0f172a;
    border-color: #334155;
}

[data-theme="dark"] .day-event-card:hover {
    background: #1e293b;
}

[data-theme="dark"] .event-time-range,
[data-theme="dark"] .event-location {
    color: #94a3b8;
}

[data-theme="dark"] .event-client,
[data-theme="dark"] .no-events-msg,
[data-theme="dark"] .legend-item,
[data-theme="dark"] .leads-summary {
    color: #64748b;
}

[data-theme="dark"] .event-type-badge.showing {
    background: rgba(5,150,105,0.2);
    color: #34d399;
}


[data-theme="dark"] .leads-header {
    background: #0f172a;
    border-bottom-color: #334155;
    color: #64748b;
}

[data-theme="dark"] .leads-row {
    border-bottom-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .col-name strong {
    color: #e2e8f0;
}

[data-theme="dark"] .lead-email,
[data-theme="dark"] .lead-phone {
    color: #64748b;
}

[data-theme="dark"] .col-date {
    color: #94a3b8;
}

[data-theme="dark"] .assign-select,
[data-theme="dark"] .btn.btn-sm {
    background: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .btn.btn-sm:hover {
    background: #334155;
}


[data-theme="dark"] .status-chip.new { background: rgba(29,78,216,0.2); color: #60a5fa; }
[data-theme="dark"] .status-chip.contacted { background: rgba(146,64,14,0.2); color: #fbbf24; }
[data-theme="dark"] .status-chip.qualified { background: rgba(6,95,70,0.2); color: #34d399; }
[data-theme="dark"] .status-chip.showing { background: rgba(91,33,182,0.2); color: #a78bfa; }
[data-theme="dark"] .status-chip.negotiating { background: rgba(157,23,77,0.2); color: #f472b6; }
[data-theme="dark"] .status-chip.closed { background: rgba(6,95,70,0.2); color: #34d399; }
[data-theme="dark"] .status-chip.lost { background: rgba(153,27,27,0.2); color: #fca5a5; }
[data-theme="dark"] .priority-chip.low { background: #334155; color: #94a3b8; }
[data-theme="dark"] .priority-chip.medium { background: rgba(29,78,216,0.2); color: #60a5fa; }
[data-theme="dark"] .priority-chip.high { background: rgba(146,64,14,0.2); color: #fbbf24; }
[data-theme="dark"] .priority-chip.urgent { background: rgba(153,27,27,0.2); color: #fca5a5; }


[data-theme="dark"] .event-status-badge.scheduled { background: rgba(29,78,216,0.2); color: #60a5fa; }
[data-theme="dark"] .event-status-badge.confirmed { background: rgba(6,95,70,0.2); color: #34d399; }
[data-theme="dark"] .event-status-badge.completed { background: #334155; color: #94a3b8; }
[data-theme="dark"] .event-status-badge.cancelled { background: rgba(153,27,27,0.2); color: #fca5a5; }
[data-theme="dark"] .event-status-badge.noshow { background: rgba(146,64,14,0.2); color: #fbbf24; }
[data-theme="dark"] .event-status-badge.rescheduled { background: rgba(91,33,182,0.2); color: #a78bfa; }


[data-theme="dark"] .lead-budget {
    background: rgba(6,95,70,0.2);
    color: #34d399;
}


[data-theme="dark"] .action-message.success {
    background: rgba(6,95,70,0.2);
    color: #6ee7b7;
    border-color: rgba(6,95,70,0.3);
}

[data-theme="dark"] .action-message.error {
    background: rgba(153,27,27,0.2);
    color: #fca5a5;
    border-color: rgba(153,27,27,0.3);
}


[data-theme="dark"] .filters-section {
    background: #1e293b;
    border-bottom-color: #334155;
}

[data-theme="dark"] .search-box,
[data-theme="dark"] .filter-group select,
[data-theme="dark"] .filter-group input {
    background: #0f172a;
    border-color: #334155;
    color: #e2e8f0;
}

[data-theme="dark"] .search-box input {
    background: transparent;
    color: #e2e8f0;
}

[data-theme="dark"] .search-box input::placeholder {
    color: #64748b;
}


[data-theme="dark"] .form-section {
    border-bottom-color: rgba(255,255,255,0.05);
}

[data-theme="dark"] .form-section h2 {
    background: linear-gradient(135deg, #818cf8 0%, #a78bfa 100%);
    -webkit-background-clip: text;
    background-clip: text;
}

[data-theme="dark"] .section-description {
    color: #94a3b8;
}


[data-theme="dark"] .sidebar-footer {
    border-top-color: #334155;
}

[data-theme="dark"] .toggle-slider {
    background: #475569;
}

[data-theme="dark"] .marketing-page .error-message {
    background: rgba(153,27,27,0.2);
    color: #fca5a5;
}


.voice-assistant {
    right: auto !important;
    left: 24px !important;
}


.marketing-page { margin-bottom: 1rem; }

.marketing-page .filters-bar {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.marketing-page .filters-bar select {
    padding: 0.625rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: white;
    font-size: 0.875rem;
    min-width: 140px;
    cursor: pointer;
}

.marketing-page .loading-state {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 4rem 2rem;
    color: var(--text-gray);
}

.marketing-page .spinner {
    width: 24px;
    height: 24px;
    border: 3px solid var(--border-color);
    border-top-color: var(--primary-blue);
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
}

.materials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.25rem;
    margin-bottom: 1.5rem;
}

.material-card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: box-shadow 0.2s, transform 0.2s;
}

.material-card:hover {
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    transform: translateY(-2px);
}

.material-thumbnail {
    position: relative;
    height: 180px;
    background: var(--bg-light);
    overflow: hidden;
}

.material-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.thumbnail-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-light);
    background: linear-gradient(135deg, #f8fafc, #e2e8f0);
}

.material-status {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    padding: 0.25rem 0.625rem;
    border-radius: 20px;
    font-size: 0.6875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.status-draft { background: #f1f5f9; color: #64748b; }
.status-generating { background: #fef3c7; color: #d97706; }
.status-ready { background: #dcfce7; color: #16a34a; }
.status-published { background: rgba(8,49,105,0.1); color: var(--primary-blue); }
.status-archived { background: #f1f5f9; color: #94a3b8; }

.material-info { padding: 1rem 1.25rem; }

.material-info h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-dark);
    margin: 0 0 0.25rem;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.material-property {
    font-size: 0.8125rem;
    color: var(--text-gray);
    margin: 0 0 0.75rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.material-meta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
}

.material-type {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--primary-blue);
    background: rgba(8,49,105,0.06);
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
}

.material-date {
    font-size: 0.75rem;
    color: var(--text-light);
}

.material-stats {
    display: flex;
    gap: 1rem;
    font-size: 0.8125rem;
    color: var(--text-gray);
}

.material-stats span {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.material-stats svg { color: var(--text-light); }

.material-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    border-top: 1px solid var(--border-color);
}

.material-actions .btn-sm {
    flex: 1 1 auto;
    justify-content: center;
    white-space: nowrap;
    min-width: 0;
}

.material-actions .btn-sm.btn-ghost {
    flex: 0 0 auto;
}

.btn-sm {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.4375rem 0.75rem;
    border-radius: var(--radius-md);
    font-size: 0.8125rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    border: none;
}

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

.btn-sm.btn-primary:hover { background: var(--primary-400); }
.btn-sm.btn-primary:disabled { opacity: 0.5; cursor: not-allowed; }

.btn-sm.btn-outline {
    background: white;
    color: var(--text-dark);
    border: 1px solid var(--border-color);
}

.btn-sm.btn-outline:hover {
    border-color: var(--primary-blue);
    color: var(--primary-blue);
}

.btn-sm.btn-ghost {
    background: transparent;
    color: var(--text-light);
    padding: 0.375rem;
}

.btn-sm.btn-ghost:hover {
    color: #ef4444;
    background: rgba(239,68,68,0.06);
}


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

.template-card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    cursor: pointer;
    transition: all 0.2s;
}

.template-card:hover {
    border-color: var(--primary-blue);
    box-shadow: 0 4px 16px rgba(8,49,105,0.1);
}

.template-thumbnail {
    position: relative;
    height: 140px;
    background: var(--bg-light);
    overflow: hidden;
}

.template-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.premium-badge {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    padding: 0.2rem 0.5rem;
    background: linear-gradient(135deg, #D4A03C, #F5C862);
    color: white;
    font-size: 0.625rem;
    font-weight: 700;
    text-transform: uppercase;
    border-radius: 4px;
}

.template-info { padding: 0.75rem 1rem; }

.template-info h4 {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-dark);
    margin: 0 0 0.25rem;
}

.template-type {
    font-size: 0.75rem;
    color: var(--text-gray);
}


.marketing-page .pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 1rem 0;
    font-size: 0.875rem;
    color: var(--text-gray);
}

.btn-nav {
    padding: 0.5rem 1rem;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    color: var(--text-dark);
    transition: all 0.2s;
}

.btn-nav:hover:not(:disabled) {
    border-color: var(--primary-blue);
    color: var(--primary-blue);
}

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


.marketing-page .modal-content {
    background: white;
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 560px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0,0,0,0.2);
}

.marketing-page .modal-content.modal-lg { max-width: 640px; }

.marketing-page .modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.marketing-page .modal-header h2 {
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0;
}

.marketing-page .modal-close {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-md);
    border: none;
    background: transparent;
    font-size: 1.5rem;
    color: var(--text-gray);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.marketing-page .modal-close:hover {
    background: var(--bg-light);
    color: var(--text-dark);
}

.marketing-page .modal-body { padding: 1.5rem; }

.marketing-page .modal-body .form-group { margin-bottom: 1.25rem; }

.marketing-page .modal-body .form-group label {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 0.375rem;
}

.marketing-page .modal-body .form-group input,
.marketing-page .modal-body .form-group select,
.marketing-page .modal-body .form-group textarea {
    width: 100%;
    padding: 0.625rem 0.875rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 0.9375rem;
    font-family: inherit;
    box-sizing: border-box;
    transition: border-color 0.2s;
}

.marketing-page .modal-body .form-group input:focus,
.marketing-page .modal-body .form-group select:focus,
.marketing-page .modal-body .form-group textarea:focus {
    outline: none;
    border-color: var(--primary-blue);
}

.marketing-page .modal-body .form-group textarea {
    resize: vertical;
    min-height: 60px;
}

.marketing-page .form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.marketing-page .checkboxes {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.marketing-page .checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    cursor: pointer;
}

.marketing-page .checkbox-label input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--primary-blue);
}

.marketing-page .error-message {
    padding: 0.75rem 1rem;
    background: #FEE2E2;
    color: #DC2626;
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    margin-top: 0.5rem;
}

.marketing-page .modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--border-color);
}

.marketing-page .modal-footer .btn-primary {
    padding: 0.625rem 1.25rem;
    background: var(--primary-blue);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 0.9375rem;
    cursor: pointer;
}

.marketing-page .modal-footer .btn-primary:hover { background: var(--primary-400); }
.marketing-page .modal-footer .btn-primary:disabled { opacity: 0.5; cursor: not-allowed; }

@media (max-width: 768px) {
    .materials-grid { grid-template-columns: 1fr; }
    .templates-grid { grid-template-columns: repeat(2, 1fr); }
    .marketing-page .form-row { grid-template-columns: 1fr; }
    .marketing-page .checkboxes { flex-direction: column; }
}

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


.publish-tabs { display: flex; border-bottom: 1px solid #e5e7eb; padding: 0 1.5rem; gap: 0; }
.publish-tab { display: flex; align-items: center; gap: 0.4rem; padding: 0.75rem 1rem; background: none; border: none; border-bottom: 2px solid transparent; color: #6b7280; font-size: 0.875rem; font-weight: 500; cursor: pointer; transition: all 0.2s; }
.publish-tab:hover { color: #083169; }
.publish-tab.active { color: #083169; border-bottom-color: #083169; font-weight: 600; }
.publish-tab svg { flex-shrink: 0; }

.publish-toggle-row { display: flex; align-items: center; justify-content: space-between; padding: 0.75rem 0; }
.toggle-switch { position: relative; display: inline-block; width: 44px; height: 24px; }
.toggle-switch input { opacity: 0; width: 0; height: 0; }
.toggle-slider { position: absolute; cursor: pointer; inset: 0; background: #d1d5db; border-radius: 24px; transition: 0.3s; }
.toggle-slider::before { content: ""; position: absolute; height: 18px; width: 18px; left: 3px; bottom: 3px; background: white; border-radius: 50%; transition: 0.3s; }
.toggle-switch input:checked + .toggle-slider { background: #083169; }
.toggle-switch input:checked + .toggle-slider::before { transform: translateX(20px); }

.share-url-box { display: flex; gap: 0.5rem; margin-top: 0.75rem; }
.share-url-box input { flex: 1; padding: 0.625rem 0.75rem; border: 1px solid #e5e7eb; border-radius: 0.5rem; font-size: 0.8125rem; background: #f9fafb; color: #374151; }
.publish-hint { color: #9ca3af; font-size: 0.875rem; margin-top: 0.5rem; }

.publish-stats-row { display: flex; gap: 1.5rem; margin-top: 1.25rem; padding-top: 1rem; border-top: 1px solid #f3f4f6; }
.publish-stat { text-align: center; }
.publish-stat-value { display: block; font-size: 1.25rem; font-weight: 700; color: #1a1a2e; }
.publish-stat-label { font-size: 0.75rem; color: #9ca3af; text-transform: uppercase; letter-spacing: 0.05em; }

.publish-message { padding: 0.625rem 0.75rem; border-radius: 0.5rem; font-size: 0.875rem; margin-top: 0.75rem; }
.publish-message.success { background: #ecfdf5; color: #065f46; border: 1px solid #a7f3d0; }
.publish-message.error { background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }


.contact-list-header { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; margin-bottom: 0.5rem; }
.contact-list-header label { font-weight: 500; font-size: 0.875rem; color: #374151; white-space: nowrap; }
.contact-search { padding: 0.5rem 0.75rem; border: 1px solid #e5e7eb; border-radius: 0.375rem; font-size: 0.8125rem; width: 200px; }
.contact-list { max-height: 280px; overflow-y: auto; border: 1px solid #e5e7eb; border-radius: 0.5rem; }
.contact-list-loading, .contact-list-empty { padding: 2rem; text-align: center; color: #9ca3af; font-size: 0.875rem; }
.contact-item { display: flex; align-items: center; gap: 0.75rem; padding: 0.625rem 0.75rem; cursor: pointer; border-bottom: 1px solid #f3f4f6; transition: background 0.15s; }
.contact-item:last-child { border-bottom: none; }
.contact-item:hover { background: #f9fafb; }
.contact-item input[type="checkbox"] { accent-color: #083169; width: 16px; height: 16px; flex-shrink: 0; }
.contact-info { display: flex; flex-direction: column; min-width: 0; }
.contact-name { font-weight: 500; font-size: 0.875rem; color: #1a1a2e; }
.contact-email { font-size: 0.75rem; color: #9ca3af; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }


.manual-email-row { display: flex; gap: 0.5rem; }
.manual-email-row input { flex: 1; padding: 0.5rem 0.75rem; border: 1px solid #e5e7eb; border-radius: 0.375rem; font-size: 0.875rem; }
.manual-email-tags { display: flex; flex-wrap: wrap; gap: 0.375rem; margin-top: 0.5rem; }
.email-tag { display: inline-flex; align-items: center; gap: 0.25rem; background: #EEF2FF; color: #083169; padding: 0.25rem 0.625rem; border-radius: 1rem; font-size: 0.75rem; font-weight: 500; }
.email-tag button { background: none; border: none; color: #6b7280; cursor: pointer; font-size: 1rem; padding: 0; line-height: 1; }
.email-tag button:hover { color: #ef4444; }


.social-actions { display: flex; flex-direction: column; gap: 0.75rem; margin-bottom: 1.25rem; }
.btn-block { width: 100%; display: flex; align-items: center; justify-content: center; gap: 0.5rem; padding: 0.75rem; text-decoration: none; }
.social-caption-section { margin-top: 0.5rem; }
.social-caption-section label { display: block; font-weight: 500; font-size: 0.875rem; color: #374151; margin-bottom: 0.5rem; }
.social-caption { width: 100%; min-height: 100px; padding: 0.75rem; border: 1px solid #e5e7eb; border-radius: 0.5rem; font-family: inherit; font-size: 0.8125rem; color: #374151; background: #f9fafb; resize: none; }
.social-caption-section .btn-sm { margin-top: 0.5rem; }


.btn-success, .btn-sm.btn-success { background: #059669; color: white; border-color: #059669; }
.btn-success:hover, .btn-sm.btn-success:hover { background: #047857; }




.agent-main .loading-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem;
    color: var(--text-gray, #6b7280);
}
.agent-main .loading-spinner {
    width: 40px; height: 40px;
    border: 3px solid #e5e7eb;
    border-top-color: var(--primary-blue, #2563eb);
    border-radius: 50%;
    animation: agent-spin 0.8s linear infinite;
}
@keyframes agent-spin { to { transform: rotate(360deg); } }

.agent-main .error-container {
    text-align: center;
    padding: 3rem 2rem;
    color: #6b7280;
}
.agent-main .error-container svg { margin-bottom: 1rem; }


.agent-main .export-dropdown { position: relative; }
.agent-main .export-btn {
    display: flex; align-items: center; gap: 0.4rem;
    background: #f1f5f9; border: 1px solid #e2e8f0;
    padding: 0.5rem 1rem; border-radius: 8px; cursor: pointer; font-size: 0.875rem;
}
.agent-main .export-btn:hover { background: #e2e8f0; }
.agent-main .export-menu {
    position: absolute; right: 0; top: 100%; margin-top: 4px;
    background: white; border: 1px solid #e2e8f0; border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1); z-index: 50; min-width: 160px;
}
.agent-main .export-menu button {
    display: block; width: 100%; text-align: left;
    padding: 0.6rem 1rem; border: none; background: none; cursor: pointer; font-size: 0.875rem;
}
.agent-main .export-menu button:hover { background: #f1f5f9; }


.agent-main .chart-card {
    background: white;
    border: 1px solid var(--border-color, #e5e7eb);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}
.agent-main .chart-header h2 { font-size: 1.0625rem; font-weight: 700; margin-bottom: 0.25rem; }
.agent-main .chart-subtitle { font-size: 0.8125rem; color: var(--text-gray, #6b7280); }


[data-theme="dark"] .agent-main .chart-card { background: #1e293b; border-color: #334155; }
[data-theme="dark"] .agent-main .export-menu { background: #1e293b; border-color: #334155; }
[data-theme="dark"] .agent-main .export-menu button:hover { background: #334155; }
[data-theme="dark"] .agent-main .export-btn { background: #334155; border-color: #475569; color: #e2e8f0; }


.agent-layout .toast-notification {
    opacity: 1;
    animation-fill-mode: forwards;
    padding: 0.625rem 1rem !important;
    font-size: 0.8125rem !important;
    max-width: 320px !important;
    border-radius: 0.5rem !important;
    gap: 0.5rem !important;
}

@keyframes toast-slide-in {
    from { transform: translateY(1rem); opacity: 0; }
    to   { transform: translateY(0);    opacity: 1; }
}
