/* Milestone 11 notification inbox */
.m11-notification-shell {
    max-width: 1120px;
}
.m11-notification-summary {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 10px;
}
.m11-notification-summary span {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 5px 8px;
    border: 1px solid var(--dq-line);
    border-radius: 6px;
    background: #fff;
    color: var(--dq-muted);
    font-size: 9px;
    font-weight: 750;
}
.notification-list {
    display: grid;
    gap: 0;
    overflow: hidden;
    border: 1px solid var(--dq-line);
    border-radius: 8px;
    background: #fff;
    box-shadow: var(--dq-shadow);
}
.notification-card {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 18px;
    min-height: 74px;
    padding: 11px 13px 11px 16px;
    border: 0;
    border-bottom: 1px solid #eceff1;
    border-radius: 0;
    background: #fff;
    box-shadow: none;
}
.notification-card:last-child { border-bottom: 0; }
.notification-card::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: transparent;
}
.notification-card.unread { background: #f8fbfb; }
.notification-card.unread::before { background: var(--dq-green); }
.notification-card p { margin: 2px 0; }
.notification-type {
    color: var(--dq-green-dark);
    font-size: 9px;
    font-weight: 850;
    letter-spacing: .05em;
    text-transform: uppercase;
}
.notification-card > div:first-child > p:nth-child(2) {
    color: #313a40;
    font-size: 11px;
    line-height: 1.45;
}
.notification-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 6px;
    white-space: nowrap;
}
.notification-actions form { margin: 0; }
.notification-actions .secondary-link,
.notification-actions .link-button {
    min-height: 27px;
    display: inline-flex;
    align-items: center;
    padding: 4px 7px;
    border-radius: 5px;
    font-size: 9px;
    text-decoration: none;
}
.notification-actions .secondary-link { background: #eef3fb; color: var(--dq-blue); }
.notification-actions .link-button { color: var(--dq-muted); }
.notification-actions .link-button:hover { background: #f1f3f5; }

@media (max-width: 700px) {
    .notification-card { grid-template-columns: 1fr; gap: 8px; }
    .notification-actions { justify-content: flex-start; }
}


/* v1.8.2 notification read-state grouping */
.m11-notification-shell {
    width: 100%;
    max-width: 980px;
    margin: 0 auto;
    padding-bottom: 32px;
}
.m11-notification-shell > .page-heading {
    margin-bottom: 12px;
}
.m11-notification-shell > .page-heading .muted {
    max-width: 690px;
}
.m18-notification-overview {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin: 0 0 22px;
}
.m18-notification-metric {
    position: relative;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 3px 14px;
    min-height: 82px;
    padding: 13px 15px;
    overflow: hidden;
    border: 1px solid var(--dq-line);
    border-radius: 11px;
    background: #fff;
    box-shadow: 0 5px 16px rgba(23, 63, 77, .04);
}
.m18-notification-metric::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 3px;
    background: #d9e3e6;
}
.m18-notification-metric > span {
    align-self: end;
    color: var(--dq-muted);
    font-size: 9px;
    font-weight: 800;
    letter-spacing: .055em;
    text-transform: uppercase;
}
.m18-notification-metric > strong {
    grid-row: 1 / span 2;
    grid-column: 2;
    align-self: center;
    color: var(--dq-text);
    font-size: 25px;
    line-height: 1;
}
.m18-notification-metric > small {
    color: var(--dq-muted);
    font-size: 10px;
}
.m18-notification-metric.has-unread {
    border-color: #cde8e2;
    background: linear-gradient(145deg, #f4fbf9 0%, #fff 78%);
}
.m18-notification-metric.has-unread::before,
.m18-notification-metric.is-clear::before {
    background: var(--dq-green);
}
.m18-notification-metric.has-unread > strong,
.m18-notification-metric.is-clear > strong {
    color: var(--dq-green-dark);
}
.m18-notification-section {
    margin-top: 0;
}
.m18-notification-section-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 18px;
    margin: 0 0 10px;
}
.m18-notification-section-heading h2 {
    margin: 2px 0 2px;
    font-size: 18px;
}
.m18-notification-section-heading .muted {
    margin: 0;
    font-size: 10px;
}
.m18-notification-section-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 31px;
    min-height: 31px;
    padding: 4px 9px;
    border: 1px solid #d9e3e6;
    border-radius: 999px;
    background: #f8fafb;
    color: var(--dq-muted);
    font-size: 10px;
    font-weight: 850;
    line-height: 1;
}
.notification-list {
    border-radius: 11px;
    box-shadow: 0 6px 18px rgba(23, 63, 77, .045);
}
.notification-card {
    min-height: 80px;
    padding: 13px 15px 13px 18px;
    transition: background-color .15s ease;
}
.notification-card.unread {
    background: #fbfefd;
}
.notification-card.unread::before {
    width: 4px;
    background: var(--dq-green);
}
.notification-card.unread:hover {
    background: #f5fbf9;
}
.notification-card.is-read {
    background: #fbfcfc;
    opacity: 1;
}
.notification-card.is-read::before {
    width: 3px;
    background: #dce5e7;
}
.notification-card.is-read > div:first-child > p:nth-child(2) {
    color: #59666d;
}
.m18-notification-caught-up {
    display: flex;
    align-items: center;
    gap: 14px;
    min-height: 88px;
    padding: 17px 19px;
    border: 1px solid #d4e8e3;
    border-radius: 11px;
    background: linear-gradient(135deg, #f4fbf9 0%, #fbfdfc 100%);
    box-shadow: 0 6px 18px rgba(23, 63, 77, .035);
}
.m18-caught-up-icon {
    display: inline-flex;
    flex: 0 0 40px;
    width: 40px;
    height: 40px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #e0f3ee;
    color: var(--dq-green-dark);
}
.m18-caught-up-icon svg {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 2.1;
}
.m18-notification-caught-up strong {
    display: block;
    margin-bottom: 3px;
    color: var(--dq-text);
    font-size: 12px;
}
.m18-notification-caught-up div > span {
    color: var(--dq-muted);
    font-size: 10px;
}
.m18-read-notifications {
    margin-top: 16px;
    overflow: hidden;
    border: 1px solid var(--dq-line);
    border-radius: 11px;
    background: #fff;
    box-shadow: 0 6px 18px rgba(23, 63, 77, .04);
}
.m18-read-notifications > summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 72px;
    padding: 12px 14px;
    cursor: pointer;
    list-style: none;
    user-select: none;
    background: #fafcfc;
    transition: background-color .15s ease;
}
.m18-read-notifications > summary:hover {
    background: #f5f8f8;
}
.m18-read-notifications > summary::-webkit-details-marker {
    display: none;
}
.m18-read-summary-main {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 11px;
}
.m18-read-summary-icon {
    display: inline-flex;
    flex: 0 0 38px;
    width: 38px;
    height: 38px;
    align-items: center;
    justify-content: center;
    border: 1px solid #dde6e8;
    border-radius: 9px;
    background: #fff;
    color: #5f6f76;
}
.m18-read-summary-icon svg {
    width: 19px;
    height: 19px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.7;
}
.m18-read-summary-copy {
    display: grid;
    min-width: 0;
    gap: 2px;
}
.m18-read-summary-copy strong {
    color: var(--dq-text);
    font-size: 12px;
}
.m18-read-summary-copy small {
    color: var(--dq-muted);
    font-size: 10px;
}
.m18-read-summary-meta {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 9px;
}
.m18-read-chevron {
    display: inline-flex;
    width: 28px;
    height: 28px;
    align-items: center;
    justify-content: center;
    border-radius: 7px;
    color: var(--dq-muted);
    transition: transform .16s ease, background-color .16s ease;
}
.m18-read-chevron svg {
    width: 17px;
    height: 17px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.8;
}
.m18-read-notifications > summary:hover .m18-read-chevron {
    background: #edf2f3;
}
.m18-read-notifications[open] .m18-read-chevron {
    transform: rotate(180deg);
}
.m18-read-notifications[open] > summary {
    background: #f7fafa;
}
.m18-read-notification-body {
    border-top: 1px solid var(--dq-line);
}
.m18-read-notification-body .notification-list {
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

@media (max-width: 700px) {
    .m11-notification-shell {
        max-width: none;
    }
    .m18-notification-overview {
        grid-template-columns: 1fr;
        gap: 8px;
        margin-bottom: 18px;
    }
    .m18-notification-metric {
        min-height: 68px;
    }
    .m18-notification-section-heading {
        align-items: center;
    }
    .m18-read-notifications > summary {
        min-height: 68px;
        padding: 11px 12px;
    }
    .m18-read-summary-icon {
        display: none;
    }
    .m18-read-summary-copy small {
        max-width: 220px;
    }
}
