/**
 * fh-kundali.css v1.0.0
 * =====================
 * Styles for the Kundali Event & Reminder Module tab.
 * Follows existing fh-*.css conventions.
 */

/* ── Panel container ── */
.gp-kd-panel {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 400px;
}

/* ── Toolbar ── */
.gp-kd-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
    border-bottom: 1px solid #e2e8f0;
    background: #f8fafc;
    gap: 10px;
    flex-shrink: 0;
}
.gp-kd-toolbar-left,
.gp-kd-toolbar-right {
    display: flex;
    align-items: center;
    gap: 8px;
}
.gp-kd-view-sel {
    padding: 6px 10px;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    font-size: 13px;
    background: #fff;
    color: #334155;
    cursor: pointer;
}
.gp-kd-view-sel:focus {
    outline: none;
    border-color: #6366f1;
    box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.15);
}

/* ── Content area ── */
.gp-kd-content {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
}

/* ── Dashboard ── */
.gp-kd-dashboard {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.gp-kd-stats-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
    gap: 10px;
}

.gp-kd-stat-card {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 14px;
    text-align: center;
    transition: box-shadow 0.2s;
}
.gp-kd-stat-card:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}
.gp-kd-stat-num {
    font-size: 24px;
    font-weight: 700;
    color: #1e293b;
    line-height: 1.2;
}
.gp-kd-stat-label {
    font-size: 11px;
    color: #94a3b8;
    margin-top: 2px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* ── Section titles ── */
.gp-kd-section {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.gp-kd-section-title {
    font-size: 14px;
    font-weight: 600;
    color: #334155;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 6px;
}

/* ── Event list ── */
.gp-kd-event-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.gp-kd-event-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    gap: 12px;
    transition: border-color 0.15s, box-shadow 0.15s;
    cursor: default;
}
.gp-kd-event-row:hover {
    border-color: #c7d2fe;
    box-shadow: 0 1px 4px rgba(99, 102, 241, 0.08);
}
.gp-kd-event-row-full {
    padding: 12px 14px;
}
.gp-kd-event-main {
    flex: 1;
    min-width: 0;
}
.gp-kd-event-title {
    font-size: 14px;
    font-weight: 600;
    color: #1e293b;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.gp-kd-event-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    margin-top: 4px;
    font-size: 12px;
    color: #64748b;
}
.gp-kd-event-profile {
    color: #6366f1;
    font-weight: 500;
}
.gp-kd-event-desc {
    font-size: 12px;
    color: #94a3b8;
    margin-top: 4px;
    line-height: 1.4;
}
.gp-kd-event-type {
    color: #94a3b8;
}
.gp-kd-event-right {
    text-align: right;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
}
.gp-kd-event-date {
    font-size: 13px;
    font-weight: 500;
    color: #334155;
}
.gp-kd-event-countdown {
    font-size: 11px;
    color: #f59e0b;
    font-weight: 600;
}
.gp-kd-event-actions {
    display: flex;
    gap: 4px;
    margin-top: 4px;
}

/* ── Badges ── */
.gp-kd-badge {
    display: inline-flex;
    align-items: center;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 7px;
    border-radius: 4px;
    text-transform: capitalize;
    white-space: nowrap;
}

.gp-kd-cat-tag {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    font-size: 11px;
    font-weight: 500;
}

/* ── Icon buttons ── */
.gp-kd-icon-btn {
    width: 28px;
    height: 28px;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    background: #fff;
    color: #64748b;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    transition: all 0.15s;
}
.gp-kd-icon-btn:hover {
    background: #f1f5f9;
    border-color: #cbd5e1;
    color: #334155;
}
.gp-kd-icon-btn-success {
    color: #10b981;
    border-color: #10b98130;
}
.gp-kd-icon-btn-success:hover {
    background: #10b98115;
    color: #059669;
}
.gp-kd-icon-btn-danger {
    color: #ef4444;
    border-color: #ef444430;
}
.gp-kd-icon-btn-danger:hover {
    background: #ef444415;
    color: #dc2626;
}

/* ── Profiles grid ── */
.gp-kd-profiles-grid {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.gp-kd-profile-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    transition: border-color 0.15s, box-shadow 0.15s;
}
.gp-kd-profile-card:hover {
    border-color: #c7d2fe;
    box-shadow: 0 2px 8px rgba(99, 102, 241, 0.08);
}
.gp-kd-pc-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: linear-gradient(135deg, #eef2ff, #e0e7ff);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    color: #6366f1;
    flex-shrink: 0;
}
.gp-kd-pc-info {
    flex: 1;
    min-width: 0;
}
.gp-kd-pc-name {
    font-size: 15px;
    font-weight: 600;
    color: #1e293b;
}
.gp-kd-pc-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 3px;
    font-size: 12px;
    color: #64748b;
}
.gp-kd-pc-meta i {
    margin-right: 3px;
    color: #94a3b8;
}
.gp-kd-pc-stats {
    display: flex;
    gap: 6px;
    margin-top: 6px;
}
.gp-kd-pc-actions {
    display: flex;
    gap: 4px;
    flex-shrink: 0;
}

/* ── Profile detail ── */
.gp-kd-profile-detail {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.gp-kd-back-btn {
    background: none;
    border: none;
    color: #6366f1;
    font-size: 13px;
    cursor: pointer;
    padding: 0;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    align-self: flex-start;
}
.gp-kd-back-btn:hover {
    color: #4f46e5;
    text-decoration: underline;
}
.gp-kd-pd-header {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 14px;
    background: linear-gradient(135deg, #faf5ff, #eef2ff);
    border-radius: 10px;
    border: 1px solid #e0e7ff;
}
.gp-kd-pd-avatar {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, #c7d2fe, #a5b4fc);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: #4338ca;
    flex-shrink: 0;
}
.gp-kd-pd-info {
    flex: 1;
    min-width: 0;
}
.gp-kd-pd-info h3 {
    margin: 0 0 4px;
    font-size: 18px;
    color: #1e293b;
}
.gp-kd-pd-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    font-size: 13px;
    color: #64748b;
}
.gp-kd-pd-meta i {
    margin-right: 3px;
    color: #94a3b8;
}
.gp-kd-pd-notes {
    margin-top: 8px;
    font-size: 13px;
    color: #475569;
    line-height: 1.5;
    background: #fff;
    padding: 8px 10px;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
}

/* ── Empty state ── */
.gp-kd-empty-state {
    text-align: center;
    padding: 40px 20px;
    color: #64748b;
}
.gp-kd-empty-state i {
    font-size: 2.5em;
    opacity: 0.3;
    margin-bottom: 10px;
    display: block;
}
.gp-kd-empty-state p {
    margin: 6px 0;
}

/* ── Form grid ── */
.gp-kd-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

/* ── Channel checkboxes ── */
.gp-kd-channel-checks {
    display: flex;
    gap: 12px;
    padding: 6px 0;
}
.gp-kd-channel-checks label {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    color: #334155;
    cursor: pointer;
}

/* ── Age hint ── */
.gp-kd-hint {
    display: block;
    font-size: 11px;
    color: #6366f1;
    margin-top: 4px;
}

/* ── Responsive ── */
@media (max-width: 600px) {
    .gp-kd-stats-row {
        grid-template-columns: repeat(2, 1fr);
    }
    .gp-kd-form-grid {
        grid-template-columns: 1fr;
    }
    .gp-kd-event-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }
    .gp-kd-event-right {
        align-items: flex-start;
        flex-direction: row;
        gap: 8px;
    }
    .gp-kd-profile-card {
        flex-wrap: wrap;
    }
    .gp-kd-pc-actions {
        width: 100%;
        justify-content: flex-end;
        margin-top: 4px;
    }
    .gp-kd-pd-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    .gp-kd-pd-meta {
        justify-content: center;
    }
}