/* ================================================================
   PROJECT MEMORY — theme-clean-reminders.css
   Reminders panel only: tab bar, search, card container,
   reminder cards, badges, recurring group, alert chips,
   and empty/loading states.
   Does NOT contain modal or banner styles — those live in
   theme-clean-modals.css and theme-clean-shared.css respectively.
   Depends on: theme-clean.css (tokens)
   ================================================================ */


/* ----------------------------------------------------------------
   TAB BAR
   ---------------------------------------------------------------- */

/**
 * @pm-registry
 * @prefix pm
 * @description Tab bar row at the top of the reminders panel.
 *   Contains Pending, Done, + Add, and voice settings tabs.
 * @apps project-memory
 * @type        css-class
 * @name        pm-reminders-tab-bar
 * @tags        TODO
 * @called-by   pm-panel-important-dates.html, pm-panel-reminders.html
 * @depends-on  --pm-border, --pm-panel-surface
 * @updated 2026-04-13
 */
.pm-reminders-tab-bar {
    display: flex;
    gap: 4px;
    padding: 8px 10px 0;
    border-bottom: 1px solid var(--pm-border);
    background: var(--pm-panel-surface);
    flex-shrink: 0;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

/**
 * @pm-registry
 * @prefix pm
 * @description Individual tab button inside pm-reminders-tab-bar.
 *   pm-active state set by reminderService.js on tab switch.
 * @apps project-memory
 * @type        css-class
 * @name        pm-reminders-tab
 * @tags        TODO
 * @called-by   pm-panel-important-dates.html, pm-panel-reminders.html
 * @depends-on  --pm-radius-small, --pm-text-3
 * @updated 2026-04-13
 */
.pm-reminders-tab {
    padding: 8px 10px;
    border-radius: var(--pm-radius-small) var(--pm-radius-small) 0 0;
    font-size: clamp(0.7rem, 2.5vw, 0.82rem);
    font-weight: 600;
    color: var(--pm-text-3);
    background: transparent;
    border-bottom: 2px solid transparent;
    transition: color 0.15s, border-color 0.15s;
    cursor: pointer;
    white-space: nowrap;
    flex-shrink: 0;
}

.pm-reminders-tab.pm-active {
    color: var(--pm-brand);
    border-bottom-color: var(--pm-brand);
}

/**
 * @pm-registry
 * @prefix pm
 * @description + Add button in the tab bar — styled as a filled inline action button.
 * @apps project-memory
 * @type        css-class
 * @name        pm-reminders-tab-add
 * @tags        TODO
 * @called-by   pm-panel-reminders.html
 * @depends-on  --pm-radius-full, --pm-brand
 * @updated 2026-04-13
 */
.pm-reminders-tab-add {
    margin-left: auto;
    flex-shrink: 0;
    padding: 6px 12px;
    border-radius: var(--pm-radius-full);
    background: var(--pm-brand);
    color: white;
    font-size: clamp(0.7rem, 2.5vw, 0.82rem);
    font-weight: 700;
    border: none;
    cursor: pointer;
    align-self: center;
    white-space: nowrap;
    transition: opacity 0.15s;
}

.pm-reminders-tab-add:active {
    opacity: 0.8;
}


/* ----------------------------------------------------------------
   CATEGORY FILTER BAR
   ---------------------------------------------------------------- */

/**
 * @pm-registry
 * @prefix pm
 * @type css-class
 * @name pm-reminders-cat-bar
 * @tags reminders
 * @description Category filter pill row shown on the Pending tab.
 *   Hidden by default; shown when pending tab is active.
 * @called-by  pm-panel-reminders.html
 * @depends-on --pm-surface-2, --pm-border
 * @updated 2026-04-28
 */
.pm-reminders-cat-bar {
    display: none;
    flex-direction: row;
    gap: 6px;
    padding: 8px 10px;
    background: var(--pm-surface-2);
    border-bottom: 1px solid var(--pm-border);
    flex-shrink: 0;
}

.pm-reminders-cat-bar.pm-active {
    display: flex;
}

/**
 * @pm-registry
 * @prefix pm
 * @type css-class
 * @name pm-reminders-cat-pill
 * @tags reminders
 * @description Individual category filter pill. Flex-grows to share available width equally
 *   so all pills fit on screen without scrolling. pm-active = currently selected.
 * @called-by  pm-panel-reminders.html
 * @depends-on --pm-radius-full, --pm-border, --pm-surface, --pm-text-2
 * @updated 2026-04-28
 */
.pm-reminders-cat-pill {
    flex: 1;
    min-width: 0;
    padding: 5px 4px;
    border-radius: var(--pm-radius-full);
    font-size: clamp(0.62rem, 2.4vw, 0.78rem);
    font-weight: 600;
    line-height: 1.2;
    border: 1.5px solid var(--pm-border);
    background: var(--pm-surface);
    color: var(--pm-text-2);
    cursor: pointer;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: all 0.15s;
}

.pm-reminders-cat-pill.pm-active {
    background: var(--pm-brand);
    border-color: var(--pm-brand);
    color: white;
}

/* ----------------------------------------------------------------
   DONE SUB-TABS
   ---------------------------------------------------------------- */

/**
 * @pm-registry
 * @prefix pm
 * @description Sub-tab bar shown below the main tab bar when Done is active.
 *   Hidden by default, shown by reminderService when done tab is selected.
 * @apps project-memory
 * @type        css-class
 * @name        pm-reminders-done-subtabs
 * @tags        TODO
 * @called-by   pm-panel-reminders.html
 * @depends-on  --pm-surface-2, --pm-border
 * @updated 2026-04-13
 */
.pm-reminders-done-subtabs {
    display: none;
    flex-direction: row;
    gap: 6px;
    padding: 8px 14px;
    background: var(--pm-surface-2);
    border-bottom: 1px solid var(--pm-border);
    overflow-x: auto;
    flex-shrink: 0;
}

.pm-reminders-done-subtabs.pm-active {
    display: flex;
}

/**
 * @pm-registry
 * @prefix pm
 * @description Individual sub-tab button inside pm-reminders-done-subtabs.
 * @apps project-memory
 * @type        css-class
 * @name        pm-reminders-subtab
 * @tags        TODO
 * @called-by   pm-panel-reminders.html
 * @depends-on  --pm-radius-full, --pm-border, --pm-panel-surface, --pm-text-2
 * @updated 2026-04-13
 */
.pm-reminders-subtab {
    padding: 4px 14px;
    border-radius: var(--pm-radius-full);
    font-size: 0.78rem;
    font-weight: 600;
    border: 1.5px solid var(--pm-border);
    background: var(--pm-panel-surface);
    color: var(--pm-text-2);
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.15s;
    flex-shrink: 0;
}

.pm-reminders-subtab.pm-active {
    background: var(--pm-brand);
    border-color: var(--pm-brand);
    color: white;
}


/* ----------------------------------------------------------------
   SEARCH
   ---------------------------------------------------------------- */

/**
 * @pm-registry
 * @prefix pm
 * @description Search input wrapper inside reminders panel.
 * @apps project-memory
 * @type        css-class
 * @name        pm-reminders-search
 * @tags        TODO
 * @called-by   pm-panel-reminders.html
 * @depends-on  --pm-panel-surface, --pm-border
 * @updated 2026-04-13
 */
.pm-reminders-search {
    padding: 10px 14px 8px;
    background: var(--pm-panel-surface);
    border-bottom: 1px solid var(--pm-border);
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

/**
 * @pm-registry
 * @prefix pm
 * @description Row of tappable search hint chips below the search input.
 * @apps project-memory
 * @type        css-class
 * @name        pm-reminders-search-hints
 * @tags        TODO
 * @called-by   none found
 * @depends-on  none
 * @updated 2026-04-13
 */
.pm-reminders-search-hints {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
}

/**
 * @pm-registry
 * @prefix      pm
 * @type        css-class
 * @name        pm-reminders-search-hints-label
 * @tags        reminders
 * @description Small uppercase label for the search hints section.
 * @depends-on  --pm-text-3
 * @called-by  none found
 * @updated     2026-04-15
 */
.pm-reminders-search-hints-label {
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--pm-text-3);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    flex-shrink: 0;
}

/**
 * @pm-registry
 * @prefix pm
 * @description Individual tappable search hint chip.
 *   pm-active state applied when that filter is current.
 * @apps project-memory
 * @type        css-class
 * @name        pm-reminders-search-hint
 * @tags        TODO
 * @called-by   none found
 * @depends-on  --pm-radius-full, --pm-border, --pm-surface-2, --pm-text-2
 * @updated 2026-04-13
 */
.pm-reminders-search-hint {
    padding: 3px 10px;
    border-radius: var(--pm-radius-full);
    font-size: 0.75rem;
    font-weight: 600;
    border: 1.5px solid var(--pm-border);
    background: var(--pm-surface-2);
    color: var(--pm-text-2);
    cursor: pointer;
    transition: all 0.15s;
    white-space: nowrap;
}

.pm-reminders-search-hint.pm-active {
    background: var(--pm-brand);
    border-color: var(--pm-brand);
    color: white;
}


/* ----------------------------------------------------------------
   CARD CONTAINER
   ---------------------------------------------------------------- */

/**
 * @pm-registry
 * @prefix pm
 * @description Scrollable container for reminder cards.
 *   Populated by reminderService.js.
 * @apps project-memory
 * @type        css-class
 * @name        pm-reminders-container
 * @tags        TODO
 * @called-by   pm-panel-calendar.html, pm-panel-important-dates.html, pm-panel-reminders.html
 * @depends-on  --pm-safe-bottom
 * @updated 2026-04-13
 */
.pm-reminders-container {
    flex: 1;
    overflow-y: auto;
    padding: 12px 0 calc(var(--pm-safe-bottom) + 16px);
}


/* ----------------------------------------------------------------
   REMINDER CARD
   ---------------------------------------------------------------- */

/**
 * @pm-registry
 * @prefix pm
 * @description Single reminder card in the pending or done list.
 * @apps project-memory
 * @type        css-class
 * @name        pm-card-reminder
 * @tags        TODO
 * @called-by   none found
 * @depends-on  --pm-panel-surface, --pm-radius-medium, --pm-border, --pm-shadow-small
 * @updated 2026-04-13
 */
.pm-card-reminder {
    background: var(--pm-panel-surface);
    border-radius: var(--pm-radius-medium);
    border: 1px solid var(--pm-border);
    padding: 14px;
    margin-bottom: 10px;
    box-shadow: var(--pm-shadow-small);
    transition: opacity 0.2s;
}

/**
 * @pm-registry
 * @prefix pm
 * @description Reminder card title line.
 * @apps project-memory
 * @type        css-class
 * @name        pm-card-reminder-title
 * @tags        TODO
 * @called-by   none found
 * @depends-on  --pm-text-1
 * @updated 2026-04-13
 */
.pm-card-reminder-title {
    font-size: 0.98rem;
    font-weight: 700;
    color: var(--pm-text-1);
    margin-bottom: 4px;
}

/**
 * @pm-registry
 * @prefix pm
 * @description Badge row below reminder card title — status tags aligned LHS.
 * @apps project-memory
 * @type        css-class
 * @name        pm-card-reminder-badges
 * @tags        TODO
 * @called-by   none found
 * @depends-on  none
 * @updated 2026-04-28
 */
.pm-card-reminder-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-bottom: 4px;
}

/**
 * @pm-registry
 * @prefix pm
 * @description Due date/time line on a reminder card.
 * @apps project-memory
 * @type        css-class
 * @name        pm-card-reminder-due
 * @tags        TODO
 * @called-by   none found
 * @depends-on  --pm-text-3
 * @updated 2026-04-13
 */
.pm-card-reminder-due {
    font-size: 0.82rem;
    color: var(--pm-text-3);
    margin-bottom: 4px;
}

/**
 * @pm-registry
 * @prefix pm
 * @description Optional notes line on a reminder card.
 * @apps project-memory
 * @type        css-class
 * @name        pm-card-reminder-notes
 * @tags        TODO
 * @called-by   none found
 * @depends-on  --pm-text-2
 * @updated 2026-04-13
 */
.pm-card-reminder-notes {
    font-size: 0.82rem;
    color: var(--pm-text-2);
    margin-bottom: 8px;
}

/**
 * @pm-registry
 * @prefix pm
 * @description Completed date line shown on done reminder cards.
 * @apps project-memory
 * @type        css-class
 * @name        pm-card-reminder-completed
 * @tags        TODO
 * @called-by   none found
 * @depends-on  --pm-success
 * @updated 2026-04-13
 */
.pm-card-reminder-completed {
    font-size: 0.8rem;
    color: var(--pm-success);
    margin-bottom: 8px;
}

/**
 * @pm-registry
 * @prefix pm
 * @description Action button row at the bottom of a reminder card.
 * @apps project-memory
 * @type        css-class
 * @name        pm-card-reminder-actions
 * @tags        TODO
 * @called-by   none found
 * @depends-on  none
 * @updated 2026-04-13
 */
.pm-card-reminder-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 8px;
}

/* Reminder card buttons — 30% smaller than the base 44px/1.8rem defaults */
.pm-card-reminder-actions .pm-button-inline,
.pm-card-reminder-actions .pm-button-delete-inline {
    width: 31px;
    height: 31px;
    font-size: 1.26rem;
}

/* Green tick for the complete/done button */
.pm-card-reminder-actions .pm-button-inline.pm-success {
    color: var(--pm-success);
}

/* ↺ is a small Unicode glyph — boost font-size to match emoji icons */
.pm-card-reminder-actions .pm-button-inline.pm-btn-reopen {
    font-size: 1.6rem;
}


/* ----------------------------------------------------------------
   BADGES
   ---------------------------------------------------------------- */

/**
 * @pm-registry
 * @prefix pm
 * @description Status badge on reminder cards.
 *   State classes set the colour: pm-overdue, pm-soon, pm-today, pm-recurring.
 * @apps project-memory
 * @type        css-class
 * @name        pm-badge-reminder
 * @tags        TODO
 * @called-by   pm-modal-reminders-help.html
 * @depends-on  --pm-radius-full
 * @updated 2026-04-13
 */
.pm-badge-reminder {
    display: inline-block;
    padding: 2px 8px;
    border-radius: var(--pm-radius-full);
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.pm-badge-reminder.pm-overdue {
    background: var(--pm-danger-light);
    color: var(--pm-danger-dark);
}

.pm-badge-reminder.pm-soon {
    background: var(--pm-warning-background);
    color: var(--pm-warning);
}

.pm-badge-reminder.pm-today {
    background: var(--pm-brand-light);
    color: var(--pm-brand-dark);
}

.pm-badge-reminder.pm-recurring {
    background: var(--pm-reminder-light);
    color: var(--pm-reminder);
    border: 1px solid var(--pm-reminder-border);
}

.pm-badge-reminder.pm-tomorrow {
    background: var(--pm-success-light);
    color: var(--pm-success);
}

.pm-badge-reminder.pm-this-week {
    background: var(--pm-event-blue-bg);
    color: var(--pm-category-info);
}

.pm-badge-reminder.pm-this-month {
    background: var(--pm-category-purple-bg);
    color: var(--pm-category-purple);
}

.pm-badge-reminder.pm-next-30 {
    background: var(--pm-success-light);
    color: var(--pm-success);
}


/* ----------------------------------------------------------------
   RECURRING HISTORY (Recurring tab — inline on card)
   ---------------------------------------------------------------- */

/**
 * @pm-registry
 * @prefix pm
 * @description Tappable header showing completion count on a recurring card.
 *   Tap to expand/collapse the history list.
 * @apps project-memory
 * @type        css-class
 * @name        pm-recurring-history-header
 * @tags        TODO
 * @called-by   none found
 * @depends-on  none
 * @updated 2026-04-13
 */
.pm-recurring-history-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 0;
    cursor: pointer;
    margin-top: 6px;
}

/**
 * @pm-registry
 * @prefix      pm
 * @type        css-class
 * @name        pm-recurring-history-count
 * @tags        reminders
 * @description Bold label for the completion count on a recurring card.
 * @depends-on  --pm-reminder
 * @called-by  none found
 * @updated     2026-04-15
 */
.pm-recurring-history-count {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--pm-reminder);
}

/**
 * @pm-registry
 * @prefix      pm
 * @type        css-class
 * @name        pm-recurring-history-toggle
 * @tags        reminders
 * @description Small arrow or icon indicating expand/collapse state.
 * @depends-on  --pm-text-3
 * @called-by  none found
 * @updated     2026-04-15
 */
.pm-recurring-history-toggle {
    font-size: 0.9rem;
    color: var(--pm-text-3);
    transition: transform 0.2s;
}

/**
 * @pm-registry
 * @prefix pm
 * @description Expandable scrollable list of completion dates.
 *   Hidden by default, shown when pm-active is added.
 * @apps project-memory
 * @type        css-class
 * @name        pm-recurring-history-list
 * @tags        TODO
 * @called-by   none found
 * @depends-on  --pm-surface-2, --pm-radius-small, --pm-border
 * @updated 2026-04-13
 */
.pm-recurring-history-list {
    display: none;
    flex-direction: column;
    gap: 4px;
    max-height: 200px;
    overflow-y: auto;
    padding: 8px 10px;
    background: var(--pm-surface-2);
    border-radius: var(--pm-radius-small);
    border: 1px solid var(--pm-border);
    margin-bottom: 8px;
}

.pm-recurring-history-list.pm-active {
    display: flex;
}

/**
 * @pm-registry
 * @prefix      pm
 * @type        css-class
 * @name        pm-recurring-history-row
 * @tags        reminders
 * @description Single completion date entry in the recurring history list.
 * @depends-on  --pm-text-2, --pm-border
 * @called-by  none found
 * @updated     2026-04-15
 */
.pm-recurring-history-row {
    font-size: 0.82rem;
    color: var(--pm-text-2);
    padding: 3px 0;
    border-bottom: 1px solid var(--pm-border);
}

.pm-recurring-history-row:last-child {
    border-bottom: none;
}

/**
 * @pm-registry
 * @prefix      pm
 * @type        css-class
 * @name        pm-recurring-history-empty
 * @tags        reminders
 * @description Centered message shown when a recurring reminder has no history yet.
 * @depends-on  --pm-text-3
 * @called-by  none found
 * @updated     2026-04-15
 */
.pm-recurring-history-empty {
    font-size: 0.82rem;
    color: var(--pm-text-3);
    text-align: center;
    padding: 8px 0;
}


/* ----------------------------------------------------------------
   RECURRING GROUP (Done tab)
   ---------------------------------------------------------------- */

/**
 * @pm-registry
 * @prefix pm
 * @description Collapsible group header for recurring reminder history in Done tab.
 * @apps project-memory
 * @type        css-class
 * @name        pm-reminder-recurring-summary
 * @tags        TODO
 * @called-by   none found
 * @depends-on  --pm-reminder-light, --pm-radius-small, --pm-reminder
 * @updated 2026-04-13
 */
.pm-reminder-recurring-summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 14px;
    background: var(--pm-reminder-light);
    border-radius: var(--pm-radius-small);
    margin-bottom: 6px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.88rem;
    color: var(--pm-reminder);
}

/**
 * @pm-registry
 * @prefix pm
 * @description Expandable group of done recurring reminder cards.
 *   Hidden by default, shown when pm-active is added.
 * @apps project-memory
 * @type        css-class
 * @name        pm-reminder-recurring-group
 * @tags        TODO
 * @called-by   none found
 * @depends-on  none
 * @updated 2026-04-13
 */
.pm-reminder-recurring-group {
    display: none;
    padding-left: 12px;
}

.pm-reminder-recurring-group.pm-active {
    display: block;
}

/* ----------------------------------------------------------------
   EMPTY / LOADING STATES
   ---------------------------------------------------------------- */

/**
 * @pm-registry
 * @prefix pm
 * @description Empty or loading state message inside pm-reminders-container.
 * @apps project-memory
 * @type        css-class
 * @name        pm-reminders-state-message
 * @tags        TODO
 * @called-by   none found
 * @depends-on  --pm-text-3
 * @updated 2026-04-13
 */
.pm-reminders-state-message {
    text-align: center;
    color: var(--pm-text-3);
    font-size: 0.92rem;
    padding: 32px 16px;
}


/* Help modal CSS moved to theme-clean-help.css */
