/* ============================================================================
   Meetings Tab Styles
   BEM Naming: meetings-tab, meeting-card, meeting-modal
   ============================================================================ */

/* Tab Container */
.meetings-tab {
    padding: 1.5rem;
}

.meetings-tab__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color, #e5e7eb);
}

.meetings-tab__title {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary, #111827);
}

.meetings-tab__actions {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

.meetings-tab__filter {
    padding: 0.5rem 0.75rem;
    border: 1px solid var(--border-color, #d1d5db);
    border-radius: 6px;
    font-size: 0.875rem;
    background: white;
}

/* Loading, Empty, Error States */
.meetings-tab__loading,
.meetings-tab__empty,
.meetings-tab__error {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem 1rem;
    gap: 1rem;
    color: var(--text-secondary, #6b7280);
    text-align: center;
}

.meetings-tab__loading i,
.meetings-tab__empty i,
.meetings-tab__error i {
    font-size: 2.5rem;
    color: var(--text-tertiary, #9ca3af);
}

.meetings-tab__error i {
    color: var(--error-color, #ef4444);
}

.meetings-tab__empty p {
    margin: 0 0 1rem 0;
}

/* Meetings List */
.meetings-tab__list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* Meeting Card */
.meeting-card {
    padding: 1.25rem;
    background: white;
    border: 1px solid var(--border-color, #e5e7eb);
    border-radius: 8px;
    transition: all 0.2s ease;
}

.meeting-card:hover {
    border-color: var(--primary-color, #3b82f6);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.meeting-card--past {
    opacity: 0.75;
}

.meeting-card__header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 0.75rem;
}

.meeting-card__title {
    margin: 0;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary, #111827);
}

.meeting-card__date {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--primary-color, #3b82f6);
    white-space: nowrap;
}

.meeting-card__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 0.75rem;
    font-size: 0.875rem;
    color: var(--text-secondary, #6b7280);
}

.meeting-card__time,
.meeting-card__duration,
.meeting-card__location {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.meeting-card__time::before {
    content: '🕐';
}

.meeting-card__duration::before {
    content: '⏱️';
}

.meeting-card__location::before {
    content: '📍';
}

.meeting-card__attendees {
    margin-bottom: 0.75rem;
    font-size: 0.875rem;
    color: var(--text-secondary, #6b7280);
}

.meeting-card__attendees-label {
    font-weight: 500;
    margin-right: 0.25rem;
}

.meeting-card__footer {
    display: flex;
    gap: 0.5rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--border-color, #e5e7eb);
}

.meeting-card__action {
    padding: 0.375rem 0.75rem;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--primary-color, #3b82f6);
    background: transparent;
    border: 1px solid var(--primary-color, #3b82f6);
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
}

.meeting-card__action:hover {
    background: var(--primary-color, #3b82f6);
    color: white;
}

.meeting-card__action--danger {
    color: var(--error-color, #ef4444);
    border-color: var(--error-color, #ef4444);
}

.meeting-card__action--danger:hover {
    background: var(--error-color, #ef4444);
    color: white;
}

/* Calendar Event Card */
.meeting-card--calendar {
    border-left: 4px solid var(--primary-color, #3b82f6);
}

.meeting-card__title-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.meeting-card__type-badge {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 0.125rem 0.5rem;
    border-radius: 4px;
    background: var(--primary-color, #3b82f6);
    color: white;
}

/* Calendar Notice */
.meetings-tab__calendar-notice {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background: #f0f9ff;
    border: 1px solid #bae6fd;
    border-radius: 6px;
    margin-bottom: 1rem;
    font-size: 0.875rem;
    color: #0369a1;
}

.meetings-tab__calendar-notice i {
    font-size: 1rem;
}

.meetings-tab__calendar-notice a {
    color: #0284c7;
    text-decoration: underline;
}

.meetings-tab__calendar-notice a:hover {
    color: #0369a1;
}

.meetings-tab__empty .meetings-tab__calendar-notice {
    margin-top: 1rem;
    justify-content: center;
}

/* Meeting Modal */
.meeting-modal {
    max-width: 100%;
}

.meeting-modal__section {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.meeting-modal__label {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-primary, #111827);
}

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

.meeting-modal__attendees-section {
    margin-top: 0.5rem;
}

.meeting-modal__attendees-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 0.5rem;
    padding: 0.75rem;
    background: var(--background-secondary, #f9fafb);
    border: 1px solid var(--border-color, #e5e7eb);
    border-radius: 6px;
    max-height: 150px;
    overflow-y: auto;
}

.meeting-modal__attendee {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    cursor: pointer;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    transition: background 0.2s;
}

.meeting-modal__attendee:hover {
    background: var(--background-hover, #f3f4f6);
}

.meeting-modal__attendee input {
    cursor: pointer;
}

/* Meeting Notes Modal */
.meeting-notes-modal__info {
    padding: 0.75rem;
    background: var(--background-secondary, #f9fafb);
    border: 1px solid var(--border-color, #e5e7eb);
    border-radius: 6px;
    margin-bottom: 1rem;
}

.meeting-notes-modal__info p {
    margin: 0;
    font-size: 0.875rem;
    color: var(--text-secondary, #6b7280);
}

.meeting-notes-modal__list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    max-height: 400px;
    overflow-y: auto;
}

.meeting-notes-modal__empty {
    text-align: center;
    color: var(--text-tertiary, #9ca3af);
    font-style: italic;
    padding: 2rem;
}

.meeting-note-card {
    padding: 1rem;
    background: white;
    border: 1px solid var(--border-color, #e5e7eb);
    border-radius: 6px;
}

.meeting-note-card__header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
    font-size: 0.8rem;
}

.meeting-note-card__author {
    font-weight: 600;
    color: var(--text-primary, #111827);
}

.meeting-note-card__date {
    color: var(--text-tertiary, #9ca3af);
}

.meeting-note-card__content {
    font-size: 0.9rem;
    color: var(--text-secondary, #4b5563);
    line-height: 1.5;
    white-space: pre-wrap;
}

/* Linked Event Card */
.meeting-card--linked {
    border-left-color: #10b981;
}

.meeting-card--linked .meeting-card__type-badge {
    background: #10b981;
}

/* Link Event Modal */
.link-event-modal {
    min-height: 200px;
}

.link-event-modal__loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 3rem;
    color: var(--text-secondary, #6b7280);
}

.link-event-modal__empty {
    text-align: center;
    padding: 3rem;
    color: var(--text-secondary, #6b7280);
}

.link-event-modal__info {
    padding: 0.75rem 1rem;
    background: var(--background-secondary, #f9fafb);
    border: 1px solid var(--border-color, #e5e7eb);
    border-radius: 6px;
    margin-bottom: 1rem;
}

.link-event-modal__info p {
    margin: 0;
    font-size: 0.875rem;
    color: var(--text-secondary, #6b7280);
}

.link-event-modal__list {
    max-height: 400px;
    overflow-y: auto;
}

.link-event-modal__date-group {
    margin-bottom: 1rem;
}

.link-event-modal__date {
    margin: 0 0 0.5rem 0;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary, #111827);
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-color, #e5e7eb);
}

.link-event-modal__event {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem;
    margin-bottom: 0.5rem;
    background: white;
    border: 1px solid var(--border-color, #e5e7eb);
    border-radius: 6px;
    transition: all 0.2s;
}

.link-event-modal__event:hover {
    border-color: var(--primary-color, #3b82f6);
}

.link-event-modal__event--linked {
    background: #f0fdf4;
    border-color: #86efac;
}

.link-event-modal__event-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex: 1;
    min-width: 0;
}

.link-event-modal__event-time {
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-secondary, #6b7280);
    white-space: nowrap;
}

.link-event-modal__event-title {
    font-size: 0.9rem;
    color: var(--text-primary, #111827);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Responsive */
@media (max-width: 640px) {
    .meetings-tab__header {
        flex-direction: column;
        gap: 1rem;
        align-items: stretch;
    }

    .meetings-tab__actions {
        flex-direction: column;
    }

    .meeting-modal__row {
        grid-template-columns: 1fr;
    }

    .meeting-card__footer {
        flex-wrap: wrap;
    }
}
