:root {
    --ps-font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --ps-font-display: "Bricolage Grotesque", var(--ps-font-sans);
    --ps-font-brand: "Bonheur Royale", "Honfleur", Georgia, "Times New Roman", serif;

    --ps-ink: #262626;
    --ps-muted: #8e8e8e;
    --ps-border: #dbdbdb;
    --ps-surface: #fafafa;

    /* Brand — slate indigo: calm, trustworthy, editorial */
    --ps-primary: #3d5168;
    --ps-primary-hover: #2e3f52;
    --ps-primary-active: #243342;
    --ps-primary-soft: #e8edf2;
    --ps-primary-tint: #f0f4f8;

    /* Engagement — jet black for likes & notification badges */
    --ps-like: #1a1a1a;
    --ps-like-hover: #000000;

    /* Links & tags — harmonized slate */
    --ps-link: #4a6278;
    --ps-link-hover: #3d5168;
    --ps-link-soft: #e8edf2;
    --ps-link-border: #c5d0dc;

    --ps-post-gap: 24px;
}

.skip-link {
    position: absolute;
    left: -9999px;
    top: auto;
    width: 1px;
    height: 1px;
    overflow: hidden;
    z-index: 10000;
    padding: 0.5rem 0.85rem;
    border-radius: 8px;
    background: #fff;
    color: var(--ps-ink);
    font-size: 0.875rem;
    font-weight: 600;
    text-decoration: none;
    border: 1px solid var(--ps-border);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.skip-link:focus {
    left: 1rem;
    top: 1rem;
    width: auto;
    height: auto;
    overflow: visible;
}

:focus-visible {
    outline: 2px solid var(--ps-link);
    outline-offset: 2px;
}

body {
    background: var(--ps-surface);
    color: var(--ps-ink);
    font-family: var(--ps-font-sans);
    font-size: 0.9375rem;
    line-height: 1.47059;
    letter-spacing: -0.011em;
    font-feature-settings: "cv02", "cv03", "cv04", "cv11";
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
    font-family: var(--ps-font-display);
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 1.08;
}

.btn,
.form-control,
.form-select,
.navbar-nav .nav-link {
    font-family: var(--ps-font-sans);
    letter-spacing: -0.011em;
}

.signup-form {
    position: relative;
}

.signup-hp {
    position: absolute !important;
    inset: auto auto 0 0 !important;
    width: 1px !important;
    height: 1px !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    opacity: 0 !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    clip-path: inset(50%) !important;
    white-space: nowrap !important;
    pointer-events: none !important;
}



.brand-hint {
    line-height: 1.45;
}

.brand-lockup {
    display: flex;
    flex-direction: column;
    line-height: 1.15;
    text-decoration: none;
    color: inherit;
}

.brand-lockup:hover {
    color: inherit;
}

.brand-name {
    font-family: var(--ps-font-brand);
    font-weight: 400;
    font-size: 2.15rem;
    letter-spacing: 0.02em;
    line-height: 1;
    text-transform: none;
}

.brand-tagline {
    font-family: var(--ps-font-sans);
    font-size: 0.6875rem;
    font-weight: 500;
    letter-spacing: -0.006em;
    text-transform: none;
    color: var(--ps-muted);
}

.navbar-brand.brand-lockup .brand-tagline {
    margin-top: 1px;
}

.brand-tagline-pill {
    font-family: var(--ps-font-sans);
    font-size: 0.75rem;
    font-weight: 500;
    letter-spacing: -0.006em;
    text-transform: none;
    color: var(--ps-muted);
}

.site-flash {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
    padding: 0.55rem 0.75rem;
    border: 1px solid var(--ps-border);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
    animation: site-flash-in 0.22s ease;
}

.site-flash.is-leaving {
    opacity: 0;
    transform: translateY(-4px);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

@keyframes site-flash-in {
    from {
        opacity: 0;
        transform: translateY(-4px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.site-flash-text {
    font-size: 0.8125rem;
    font-weight: 500;
    letter-spacing: -0.01em;
    color: var(--ps-ink);
}

.site-flash-success {
    border-color: var(--ps-link-border);
    background: var(--ps-primary-tint);
}

.site-flash-danger {
    border-color: #e8d4cc;
    background: #faf5f2;
}

.site-flash-danger .site-flash-text {
    color: #6b4f42;
}

.site-flash-dismiss {
    flex-shrink: 0;
    border: none;
    background: transparent;
    color: var(--ps-muted);
    font-size: 1.1rem;
    line-height: 1;
    padding: 0.1rem 0.2rem;
    cursor: pointer;
    border-radius: 4px;
}

.site-flash-dismiss:hover {
    color: var(--ps-ink);
    background: rgba(0, 0, 0, 0.04);
}

.site-footer {
    max-width: 935px;
    margin: 0 auto;
    padding: 24px 16px 32px;
    text-align: center;
}

.site-footer-brand {
    border: 0;
    outline: none;
    box-shadow: none;
    background: none;
    padding: 0;
    font: inherit;
    font-size: inherit;
    color: inherit;
    letter-spacing: inherit;
    cursor: pointer;
    appearance: none;
}

.site-footer-brand:hover {
    text-decoration: underline;
}

.site-footer-link {
    color: inherit;
    text-decoration: none;
}

.site-footer-link:hover {
    text-decoration: underline;
}

.site-footer-sep {
    margin: 0 0.35rem;
    opacity: 0.45;
}

.legal-page {
    max-width: 640px;
    margin: 0 auto;
    font-size: 0.92rem;
    line-height: 1.55;
}

.legal-page h2 {
    font-weight: 600;
}

.legal-page ul {
    padding-left: 1.2rem;
}

.legal-page li + li {
    margin-top: 0.35rem;
}

.site-footer-line {
    margin: 0;
    font-size: 0.75rem;
    color: #8e8e8e;
    letter-spacing: 0.01em;
}

body.guest-gated main {
    filter: blur(4px);
    pointer-events: none;
    user-select: none;
}

.guest-signup-modal {
    border: none;
    border-radius: 16px;
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.25);
}

.ps-confirm-content {
    border: none;
    border-radius: 14px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.18);
}

.ps-confirm-modal .modal-title {
    font-size: 1.05rem;
    font-weight: 600;
    letter-spacing: -0.02em;
}

.ps-confirm-message {
    color: var(--ps-ink);
    line-height: 1.5;
}

.ps-confirm-preview {
    margin-top: 0.75rem;
    padding: 0.65rem 0.85rem;
    border-left: 3px solid var(--ps-border);
    background: #fff;
    border-radius: 0 8px 8px 0;
    color: var(--ps-muted);
    font-size: 0.875rem;
    line-height: 1.45;
}

.ps-confirm-footer-alert {
    justify-content: flex-end;
}

.ps-confirm-footer-alert .ps-confirm-ok {
    min-width: 5.5rem;
}

.guest-signup-title {
    font-family: var(--ps-font-sans);
    font-size: 1rem;
    font-weight: 500;
    letter-spacing: -0.01em;
    line-height: 1.2;
}

.guest-signup-title .brand-name {
    display: inline-block;
    margin-left: 0.12em;
    vertical-align: -0.08em;
}

.guest-signup-icon {
    width: 56px;
    height: 56px;
    margin: 0 auto;
    border-radius: 50%;
    background: #f1f3f5;
    color: var(--ps-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.navbar-main-nav .nav-link,
.navbar-user-nav .nav-link {
    display: flex;
    align-items: center;
    gap: 0.65rem;
}

@media (min-width: 992px) {
    .navbar-main-nav .nav-link {
        padding-left: 0.6rem;
        padding-right: 0.6rem;
    }
}

.navbar-user-nav .nav-link {
    min-height: 40px;
}

.navbar-main-nav .nav-link i,
.navbar-user-nav .nav-link i,
.ph,
.ph-fill {
    font-size: 1.25rem;
    line-height: 1;
    vertical-align: -0.125em;
}

.like-btn i,
.share-btn i,
.comment-like-btn i,
.post-actions i,
.story-icon-btn i,
.story-add-overlay i,
.story-lightbox-dismiss i,
.admin-sidebar .nav-link i {
    vertical-align: -0.125em;
}

.nav-link-avatar {
    flex-shrink: 0;
}

.nav-link-inbox,
.nav-link-activity {
    position: relative;
}

.nav-inbox-badge,
.nav-activity-badge {
    margin-left: auto;
    min-width: 1.15rem;
    height: 1.15rem;
    padding: 0 0.3rem;
    border-radius: 999px;
    background: #1a1a1a;
    color: #fff;
    font-size: 0.62rem;
    font-weight: 700;
    line-height: 1.15rem;
    text-align: center;
}

@media (min-width: 992px) {
    .nav-inbox-badge,
    .nav-activity-badge {
        position: absolute;
        top: 4px;
        right: 2px;
        margin-left: 0;
        min-width: 1rem;
        height: 1rem;
        font-size: 0.58rem;
        line-height: 1rem;
    }
}

.feed-preference-menu .dropdown-header {
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: var(--ps-muted);
    padding-top: 0.35rem;
    padding-bottom: 0.2rem;
}

.feed-preference-menu .dropdown-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    font-size: 0.8rem;
    padding-top: 0.35rem;
    padding-bottom: 0.35rem;
}

.feed-preference-check {
    color: var(--ps-like);
    font-weight: 700;
    font-size: 0.75rem;
}

.account-pref-toggle .form-check-input {
    cursor: pointer;
}

.account-pref-toggle .form-check-input:checked {
    background-color: var(--ps-like);
    border-color: var(--ps-like);
}

.feed-preference-dropdown .btn-link,
.post-header .dropdown > .btn-link {
    line-height: 1;
    text-decoration: none;
}

.feed-preference-dropdown .btn-link:hover,
.feed-preference-dropdown .btn-link:focus,
.feed-preference-dropdown .btn-link:focus-visible,
.post-header .dropdown > .btn-link:hover,
.post-header .dropdown > .btn-link:focus,
.post-header .dropdown > .btn-link:focus-visible {
    text-decoration: none;
}

.profile-feed-pref {
    vertical-align: middle;
}

.notifications-page {
    max-width: 640px;
    margin: 0 auto;
}

.notifications-item {
    padding: 0.85rem 1rem;
}

.notifications-item-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.notifications-item-copy {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.notifications-item-text {
    font-size: 0.9rem;
    line-height: 1.35;
}

.notifications-item-time {
    margin-top: 0.1rem;
}

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

.notifications-item-follow .notifications-item-link {
    min-width: 0;
}

.notifications-follow-form {
    flex-shrink: 0;
}

.inbox-message-highlight {
    background: rgba(255, 193, 7, 0.12);
    border-radius: 0.5rem;
    animation: inbox-highlight-fade 2.5s ease-out forwards;
}

@keyframes inbox-highlight-fade {
    0% { background: rgba(255, 193, 7, 0.22); }
    100% { background: transparent; }
}

.inbox-page {
    max-width: 640px;
    margin: 0 auto;
}

.inbox-folder-nav {
    display: flex;
    gap: 0.5rem;
    border-bottom: 1px solid #efefef;
}

.inbox-folder-tab {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.55rem 0.85rem;
    margin-bottom: -1px;
    border-bottom: 2px solid transparent;
    color: #6c757d;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
}

.inbox-folder-tab:hover {
    color: var(--ps-text);
}

.inbox-folder-tab.is-active {
    color: var(--ps-text);
    border-bottom-color: var(--ps-primary);
}

.inbox-folder-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.25rem;
    height: 1.25rem;
    padding: 0 0.35rem;
    border-radius: 999px;
    background: var(--ps-primary);
    color: #fff;
    font-size: 0.68rem;
    font-weight: 600;
    line-height: 1;
}

.inbox-folder-badge.is-muted {
    background: #e9ecef;
    color: #6c757d;
}

.mailbox-compose {
    border: 1px solid #efefef;
    box-shadow: none;
}

.inbox-thread {
    display: block;
    padding: 1rem;
}

.inbox-thread.is-unread {
    background: var(--ps-primary-tint);
}

.inbox-thread-head {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.inbox-thread-meta {
    flex: 1;
    min-width: 0;
}

.inbox-thread-messages {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    padding-left: 0.25rem;
}

.inbox-message {
    max-width: 92%;
}

.inbox-message.is-own {
    margin-left: auto;
    text-align: right;
}

.inbox-message-body {
    background: #f3f4f6;
    border-radius: 14px;
    padding: 0.55rem 0.75rem;
}

.inbox-message.is-own .inbox-message-body {
    background: var(--ps-primary-tint);
}

.inbox-message-user {
    display: block;
    font-size: 0.78rem;
    margin-bottom: 0.15rem;
}

.inbox-message-text {
    font-size: 0.9rem;
    line-height: 1.35;
    white-space: pre-wrap;
    word-break: break-word;
}

.inbox-like-inline {
    display: inline-flex;
    margin-top: 0.2rem;
}

.inbox-message.is-own .inbox-like-inline {
    justify-content: flex-end;
    width: 100%;
}

.inbox-message-time {
    display: block;
    margin-top: 0.2rem;
    font-size: 0.68rem;
}

.inbox-reply-btn,
.inbox-edit-btn,
.inbox-delete-btn {
    border: none;
    background: none;
    padding: 0;
    font-size: 0.72rem;
    font-weight: 600;
    color: #8e8e8e;
}

.inbox-reply-btn:hover,
.inbox-edit-btn:hover {
    color: #262626;
}

.inbox-delete-btn:hover {
    color: #b42318;
}

.inbox-message-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
}

.inbox-edited {
    font-style: italic;
}

.inbox-thread-actions {
    display: flex;
    align-items: flex-start;
    gap: 0.35rem;
}

.inbox-thread-archive,
.inbox-thread-delete {
    padding: 0.15rem 0.25rem;
    line-height: 1;
    opacity: 0.55;
}

.inbox-thread-archive:hover,
.inbox-thread-delete:hover {
    opacity: 1;
}

.inbox-thread-archive:hover {
    color: var(--ps-text) !important;
}

.inbox-thread-delete:hover {
    color: #b42318 !important;
}

.inbox-message.is-own .inbox-message-actions {
    text-align: right;
}

.inbox-thread-compose {
    display: flex;
    gap: 0.5rem;
    align-items: center;
    margin-bottom: 0.75rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #efefef;
}

.inbox-empty-icon {
    width: 56px;
    height: 56px;
    margin: 0 auto;
    border-radius: 50%;
    background: var(--ps-primary-tint);
    color: var(--ps-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.inbox-list .list-group-item {
    border-color: #efefef;
    padding: 0.85rem 1rem;
}

.inbox-item {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.85rem;
}

.inbox-item.is-unread {
    background: var(--ps-primary-tint);
}

.inbox-item-main {
    display: flex;
    align-items: flex-start;
    gap: 0.65rem;
    min-width: 0;
    flex: 1;
}

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

.inbox-item-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.5rem;
    margin-bottom: 0.2rem;
}

.inbox-time {
    flex-shrink: 0;
}

.inbox-text {
    font-size: 0.92rem;
    line-height: 1.4;
    word-break: break-word;
}

.inbox-item-side {
    flex-shrink: 0;
}

.inbox-story-thumb {
    display: block;
    width: 44px;
    height: 56px;
    border-radius: 6px;
    overflow: hidden;
    border: 1px solid #dbdbdb;
}

.inbox-story-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.inbox-story-expired {
    display: block;
    max-width: 4.5rem;
    text-align: right;
}

.search-form {
    width: 100%;
}

.search-form-field {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    position: relative;
    max-width: 640px;
}

.search-form-icon {
    position: absolute;
    left: 0.85rem;
    color: var(--ps-muted);
    pointer-events: none;
    line-height: 1;
}

.search-form-input {
    padding-left: 2.35rem;
    border-radius: 999px;
    border-color: #e5e5e5;
    background: #f8f9fa;
}

.search-form-input:focus {
    background: #fff;
    border-color: var(--ps-primary-soft);
    box-shadow: 0 0 0 0.2rem rgba(61, 81, 104, 0.12);
}

.search-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.search-tab {
    display: inline-flex;
    align-items: center;
    padding: 0.35rem 0.85rem;
    border-radius: 999px;
    border: 1px solid #e5e5e5;
    background: #fff;
    color: var(--ps-ink);
    font-size: 0.85rem;
    font-weight: 500;
    text-decoration: none;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.search-tab:hover {
    background: var(--ps-primary-tint);
    border-color: var(--ps-link-border);
    color: var(--ps-link-hover);
}

.search-tab.is-active {
    background: var(--ps-primary);
    border-color: var(--ps-primary);
    color: #fff;
}

.search-section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.search-section-title {
    margin: 0;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--ps-muted);
}

.search-section-more {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--ps-link);
    text-decoration: none;
}

.search-section-more:hover {
    color: var(--ps-link-hover);
    text-decoration: underline;
}

.search-results-list .list-group-item {
    border-color: #efefef;
}

@media (min-width: 992px) {
    .navbar {
        position: relative;
    }

    .navbar-top {
        display: grid;
        grid-template-columns: 1fr auto 1fr;
        align-items: center;
        position: relative;
        z-index: 2;
    }

    .navbar-brand {
        grid-column: 1;
        grid-row: 1;
        justify-self: start;
        z-index: 1;
    }

    .navbar-expand-lg .navbar-collapse.nav-drawer {
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        display: block !important;
        width: 100%;
        height: 100%;
        margin: 0;
        padding: 0;
        background: transparent;
        border: 0;
        box-shadow: none;
        overflow: visible;
        transform: none !important;
        visibility: visible !important;
        pointer-events: none;
    }

    .nav-mobile-menu {
        display: grid;
        grid-template-columns: 1fr auto 1fr;
        align-items: center;
        width: 100%;
        max-width: 935px;
        margin: 0 auto;
        padding: 0;
        pointer-events: auto;
    }

    .navbar-main-nav {
        grid-column: 2;
        justify-self: center;
        flex-direction: row;
        margin: 0;
    }

    .navbar-user-nav {
        grid-column: 3;
        justify-self: end;
        flex-direction: row;
        gap: 0.25rem;
        align-items: center;
    }

    .navbar-user-nav .nav-item-profile {
        margin-right: 0.35rem;
    }

    .navbar-user-nav .nav-item-trailing .nav-link {
        padding-left: 0.15rem;
        padding-right: 0.15rem;
    }

    .navbar-user-nav .nav-item-trailing + .nav-item-trailing {
        margin-left: -0.15rem;
    }

    .navbar-main-nav .nav-link-label,
    .navbar-user-nav .nav-item:not(.nav-item-profile):not(.nav-item-create) .nav-link-label,
    .navbar-user-nav .nav-item-create .nav-link-label,
    .navbar-user-nav .nav-item-trailing .nav-link-label {
        display: none;
    }

    .navbar-user-nav .nav-item-profile .nav-link-label {
        display: none;
    }

    @media (min-width: 768px) {
        .navbar-user-nav .nav-item-profile .nav-link-label {
            display: inline;
        }
    }
}

.nav-menu-toggle {
    width: 44px;
    height: 44px;
    padding: 0;
    border: none;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    transition: background 0.2s ease;
}

.nav-menu-toggle:hover,
.nav-menu-toggle:focus {
    background: rgba(0, 0, 0, 0.05);
    box-shadow: none;
    outline: none;
}

.nav-menu-icon {
    display: block;
    width: 20px;
    height: 14px;
    position: relative;
}

.nav-menu-bar {
    display: block;
    position: absolute;
    left: 0;
    width: 100%;
    height: 2px;
    background: #171717;
    border-radius: 1px;
    transition:
        transform 0.32s cubic-bezier(0.4, 0, 0.2, 1),
        opacity 0.2s ease,
        top 0.32s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-menu-bar:nth-child(1) {
    top: 0;
}

.nav-menu-bar:nth-child(2) {
    top: 6px;
}

.nav-menu-bar:nth-child(3) {
    top: 12px;
}

.nav-menu-toggle[aria-expanded="true"] .nav-menu-bar:nth-child(1) {
    top: 6px;
    transform: rotate(45deg);
}

.nav-menu-toggle[aria-expanded="true"] .nav-menu-bar:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.nav-menu-toggle[aria-expanded="true"] .nav-menu-bar:nth-child(3) {
    top: 6px;
    transform: rotate(-45deg);
}

.nav-drawer-backdrop {
    position: fixed;
    inset: 0;
    z-index: 1040;
    background: rgba(0, 0, 0, 0.45);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.32s ease, visibility 0.32s ease;
}

.nav-drawer-backdrop.is-visible {
    opacity: 1;
    visibility: visible;
}

@media (max-width: 991.98px) {
    .navbar {
        position: relative;
        z-index: 1060;
    }

    .navbar-collapse.nav-drawer {
        position: fixed;
        top: 0;
        right: 0;
        bottom: 0;
        left: auto;
        z-index: 1050;
        display: flex !important;
        flex-direction: column;
        align-items: stretch !important;
        justify-content: flex-start !important;
        flex-grow: 0 !important;
        width: min(320px, 88vw);
        height: 100dvh !important;
        max-height: 100dvh;
        margin: 0;
        padding: 0;
        padding-bottom: env(safe-area-inset-bottom, 0);
        background: #fff;
        border-left: 1px solid #efefef;
        box-shadow: -8px 0 40px rgba(0, 0, 0, 0.12);
        overflow: hidden;
        transform: translateX(100%);
        visibility: hidden;
        pointer-events: none;
        transition: transform 0.34s cubic-bezier(0.4, 0, 0.2, 1), visibility 0.34s ease;
        --bs-nav-link-padding-x: 0.5rem;
    }

    .navbar-collapse.nav-drawer.show {
        transform: translateX(0);
        visibility: visible;
        pointer-events: auto;
    }

    body.nav-menu-open {
        overflow: hidden;
    }

    .nav-mobile-menu {
        display: flex;
        flex-direction: column;
        flex: 1;
        align-items: stretch;
        justify-content: flex-start;
        gap: 0.5rem;
        width: 100%;
        max-width: 100%;
        min-height: 0;
        margin: 0;
        padding: 1rem 1rem max(1rem, env(safe-area-inset-bottom, 1rem));
        box-sizing: border-box;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .nav-drawer-header {
        margin: 0 0 0.75rem;
        padding: 0 0 1rem;
        border-bottom: 1px solid #efefef;
    }

    .nav-drawer-title {
        padding-left: 0;
        margin-left: 0;
    }

    .nav-drawer-title {
        display: block;
        font-family: var(--ps-font-brand);
        font-weight: 400;
        font-size: 2.15rem;
        letter-spacing: 0.02em;
        line-height: 1;
        text-transform: none;
        color: #262626;
    }

    .nav-drawer-subtitle {
        display: block;
        margin-top: 0.2rem;
        font-family: var(--ps-font-sans);
        font-size: 0.6875rem;
        font-weight: 500;
        letter-spacing: -0.006em;
        text-transform: none;
        color: var(--ps-muted);
    }

    .navbar-collapse.nav-drawer .navbar-nav {
        padding-left: 0;
        padding-right: 0;
        margin-left: 0;
        margin-right: 0;
    }

    .navbar-main-nav,
    .navbar-user-nav {
        width: 100%;
        margin: 0;
        flex-direction: column;
        align-items: stretch;
        gap: 0.15rem;
    }

    .navbar-user-nav {
        margin-top: 0.5rem;
        padding-top: 0.75rem;
        border-top: 1px solid #efefef;
    }

    .navbar-main-nav .nav-item,
    .navbar-user-nav .nav-item {
        width: 100%;
        text-align: left;
    }

    .navbar-main-nav .nav-link,
    .navbar-user-nav .nav-link {
        width: 100%;
        justify-content: flex-start;
        text-align: left;
        padding: 0.75rem 0.5rem;
        margin: 0;
        border-radius: 10px;
        font-size: 1rem;
        font-weight: 500;
        color: #262626;
        transition: background 0.15s ease;
    }

    .navbar-main-nav .nav-link:hover,
    .navbar-main-nav .nav-link:focus,
    .navbar-user-nav .nav-link:hover,
    .navbar-user-nav .nav-link:focus {
        background: #f5f5f5;
        color: #262626;
    }

    .navbar-main-nav .nav-link i,
    .navbar-user-nav .nav-link i {
        width: 1.35rem;
        text-align: center;
        flex-shrink: 0;
    }

    .nav-link-label {
        flex: 1;
    }
}

@media (min-width: 992px) {
    .nav-drawer-backdrop {
        display: none !important;
    }
}

.avatar-sm {
    width: 28px;
    height: 28px;
    object-fit: cover;
}

.user-avatar-icon {
    --shutter-glyph: 28px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    background: #eceef1;
    color: #d5d9de;
    object-fit: unset;
    overflow: hidden;
    position: relative;
}

.avatar-md.user-avatar-icon {
    --shutter-glyph: 56px;
}

.avatar-lg.user-avatar-icon {
    --shutter-glyph: 150px;
}

.user-avatar-icon > .ph,
.user-avatar-icon > .ph-fill {
    font-size: var(--shutter-glyph);
    line-height: 1;
    vertical-align: 0;
    opacity: 0.2;
    transform: scale(1.32);
    transform-origin: center center;
}

.avatar-md {
    width: 56px;
    height: 56px;
    object-fit: cover;
}

.avatar-lg {
    width: 150px;
    height: 150px;
    object-fit: cover;
}

.profile-story-avatar.story-ring,
.profile-story-avatar.story-ring-btn {
    flex: 0 0 156px;
    width: 156px;
    max-width: 156px;
    padding: 0;
    border: none;
    background: transparent;
    cursor: pointer;
    color: inherit;
    line-height: 0;
    text-align: center;
    overflow: visible;
    align-self: flex-start;
}

.profile-story-avatar .story-shutter {
    width: 150px;
    height: 150px;
    margin: 0 auto;
}

.profile-story-avatar .story-shutter:has(.story-ring-edge) {
    margin-top: 3px;
}

.profile-story-avatar .story-shutter {
    box-shadow: none;
}

.profile-story-avatar .story-shutter-glass,
.profile-story-avatar .story-shutter::after {
    display: none;
}

.profile-story-avatar .story-shutter-avatar,
.profile-story-avatar.viewed .story-shutter-avatar,
.profile-story-avatar .story-shutter.viewed .story-shutter-avatar {
    filter: none;
}

.post-card {
    background: #fff;
    border: 1px solid #dbdbdb;
    border-radius: 8px;
    margin-bottom: var(--ps-post-gap);
    overflow: visible;
}

.post-media {
    position: relative;
    display: block;
    background: #111;
}

.post-media-link {
    display: block;
}

.post-media-link-advance {
    cursor: pointer;
}

.post-media-link-advance .post-image {
    cursor: pointer;
}

.post-header-follow {
    display: inline-flex;
    align-items: baseline;
    gap: 0.35rem;
}

.post-header-follow-sep {
    color: #c7c7c7;
    font-weight: 400;
    user-select: none;
}

.post-author-follow-form {
    display: inline;
    margin: 0;
}

.post-author-follow-chip {
    border: 0;
    background: none;
    padding: 0;
    font-size: 0.75rem;
    font-weight: 600;
    line-height: 1.25;
    color: #8e8e8e;
    text-decoration: none;
    vertical-align: baseline;
    cursor: pointer;
}

.post-author-follow-chip.is-action {
    color: var(--ps-primary);
}

.post-author-follow-chip.is-action:hover,
.post-author-follow-chip.is-action:focus-visible {
    color: #1d4ed8;
    text-decoration: underline;
}

.post-author-follow-chip.is-muted {
    cursor: default;
}

.post-card img.post-image {
    width: 100%;
    height: auto;
    object-fit: cover;
    display: block;
}

.post-metadata-overlay {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.2rem 0.35rem;
    padding: 0.28rem 0.55rem;
    border-radius: 0;
    background: linear-gradient(180deg, rgba(12, 16, 22, 0.28) 0%, rgba(12, 16, 22, 0.72) 100%);
    color: rgba(255, 255, 255, 0.92);
    font-size: 0.6rem;
    line-height: 1.15;
    letter-spacing: 0.01em;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
    pointer-events: none;
    opacity: 0;
    transform: translateY(4px);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.post-metadata-segment {
    white-space: nowrap;
}

.post-metadata-segment:first-child {
    font-weight: 600;
}

.post-metadata-sep {
    opacity: 0.45;
    font-size: 0.5rem;
    line-height: 1;
}

body.feed-show-metadata .post-metadata-overlay {
    opacity: 1;
    transform: translateY(0);
}

.feed-metadata-toggle {
    padding: 0.15rem 0;
}

.feed-metadata-label {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.feed-metadata-toggle .form-check-input {
    cursor: pointer;
}

.feed-metadata-switch:checked {
    background-color: #525252;
    border-color: #525252;
}

.feed-metadata-switch:focus {
    border-color: #adb5bd;
    box-shadow: 0 0 0 0.2rem rgba(82, 82, 82, 0.2);
}

.feed-metadata-switch:checked:focus {
    background-color: #525252;
    border-color: #525252;
    box-shadow: 0 0 0 0.2rem rgba(82, 82, 82, 0.25);
}

.feed-sidebar-section + .feed-sidebar-metadata {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #efefef;
}

.feed-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 2rem;
    align-items: start;
}

.feed-main {
    min-width: 0;
}

.feed-scroll-sentinel {
    height: 1px;
    width: 100%;
    pointer-events: none;
}

.feed-scroll-status[hidden] {
    display: none !important;
}

.feed-sidebar {
    display: none;
}

@media (min-width: 992px) {
    .feed-layout {
        grid-template-columns: minmax(0, 600px) 200px;
        justify-content: center;
        gap: 2rem;
    }

    .feed-sidebar {
        display: block;
        position: sticky;
        top: 1.25rem;
    }
}

@media (max-width: 991.98px) {
    .feed-layout .feed-sidebar {
        display: block;
    }
}

.feed-sidebar .avatar-sm {
    width: 24px;
    height: 24px;
}

.feed-sidebar-section + .feed-sidebar-section {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
}

.feed-sidebar-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.feed-sidebar-title {
    margin: 0;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--ps-muted);
}

.feed-sidebar-more {
    font-size: 0.7rem;
    font-weight: 500;
    color: var(--ps-muted);
    text-decoration: none;
}

.feed-sidebar-more:hover {
    color: var(--ps-link);
}

.feed-sidebar-user {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.3rem 0;
}

.feed-sidebar-user-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    min-width: 0;
    flex: 1;
}

.feed-sidebar-user-copy {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.feed-sidebar-user-name {
    font-size: 0.78rem;
    font-weight: 600;
    line-height: 1.25;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.feed-sidebar-user-hint {
    font-size: 0.68rem;
    line-height: 1.25;
    color: var(--ps-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.feed-sidebar-user-form {
    flex-shrink: 0;
    margin: 0;
}

.feed-sidebar-follow-btn {
    padding: 0;
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--ps-ink);
    text-decoration: none;
    white-space: nowrap;
}

.feed-sidebar-follow-btn:hover {
    color: var(--ps-link);
}

.feed-sidebar-follow-btn.is-follow {
    color: var(--ps-link);
}

.feed-sidebar-follow-btn.is-follow:hover {
    color: var(--ps-link-hover);
}

.feed-sidebar-user-action {
    flex-shrink: 0;
    font-size: 0.65rem;
    line-height: 1.2;
    text-align: right;
    max-width: 4.5rem;
}

.feed-onboarding {
    border-color: var(--ps-border);
    box-shadow: none;
}

.feed-onboarding .card-body {
    background: var(--ps-surface);
}

.feed-discovery-label {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.post-header,
.post-likes-zone,
.post-caption,
.post-comments {
    padding: 12px 16px;
}

.hashtag-link {
    color: var(--ps-link);
    text-decoration: none;
    font-weight: 500;
}

.hashtag-link:hover {
    color: var(--ps-link-hover);
    text-decoration: underline;
}

.hashtag-trending-title {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: #8e8e8e;
    margin-bottom: 0.65rem;
}

.explore-hashtags {
    --explore-tags-ease: cubic-bezier(0.22, 1, 0.36, 1);
    --explore-tags-ease-out: cubic-bezier(0.33, 1, 0.68, 1);
    --explore-tags-duration: 0.44s;
}

/* Visibility is driven by .is-collapsed, not the native details open state. */
.explore-hashtags > .explore-hashtags-panel {
    display: grid;
}

.explore-hashtags > summary {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 0.45rem;
    cursor: pointer;
    user-select: none;
    padding: 0.15rem 0;
    margin-bottom: 0.6rem;
    transition: margin-bottom var(--explore-tags-duration) var(--explore-tags-ease);
}

.explore-hashtags > summary::-webkit-details-marker {
    display: none;
}

.explore-hashtags-label {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: #8e8e8e;
}

.explore-hashtags-hint {
    font-size: 0.72rem;
    transition: opacity 0.28s var(--explore-tags-ease);
}

.explore-hashtags > summary::after {
    content: '';
    width: 0.35rem;
    height: 0.35rem;
    margin-left: auto;
    border-right: 1.5px solid var(--ps-muted);
    border-bottom: 1.5px solid var(--ps-muted);
    transform: rotate(-135deg);
    transition:
        transform var(--explore-tags-duration) var(--explore-tags-ease-out),
        top var(--explore-tags-duration) var(--explore-tags-ease-out);
    position: relative;
    top: 0;
}

.explore-hashtags.is-collapsed > summary {
    margin-bottom: 0;
}

.explore-hashtags.is-collapsed > summary::after {
    transform: rotate(45deg);
    top: -0.1rem;
}

.explore-hashtags-panel {
    display: grid;
    grid-template-rows: 1fr;
    opacity: 1;
    transform: translateY(0);
    transition:
        grid-template-rows var(--explore-tags-duration) var(--explore-tags-ease),
        opacity calc(var(--explore-tags-duration) * 0.85) var(--explore-tags-ease) 0.05s,
        transform var(--explore-tags-duration) var(--explore-tags-ease);
}

.explore-hashtags.is-collapsed .explore-hashtags-panel {
    grid-template-rows: 0fr;
    opacity: 0;
    transform: translateY(-0.28rem);
    pointer-events: none;
    transition:
        grid-template-rows 0.38s cubic-bezier(0.4, 0, 0.2, 1),
        opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1),
        transform 0.38s cubic-bezier(0.4, 0, 0.2, 1);
}

.explore-hashtags-panel > .hashtag-trending-list {
    min-height: 0;
    overflow: hidden;
}

.explore-hashtags:not(.is-collapsed) .hashtag-trending-list {
    overflow: visible;
}

@media (prefers-reduced-motion: reduce) {
    .explore-hashtags > summary,
    .explore-hashtags > summary::after,
    .explore-hashtags-hint,
    .explore-hashtags-panel {
        transition: none;
    }
}

.hashtag-trending-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.hashtag-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.35rem 0.7rem;
    border-radius: 999px;
    background: #fff;
    border: 1px solid #e5e5e5;
    color: var(--ps-link);
    font-size: 0.85rem;
    font-weight: 500;
    text-decoration: none;
    transition: background 0.15s ease, border-color 0.15s ease;
}

.hashtag-pill:hover {
    background: var(--ps-link-soft);
    border-color: var(--ps-link-border);
    color: var(--ps-link-hover);
}

.hashtag-pill-count {
    font-size: 0.72rem;
    font-weight: 600;
    color: #8e8e8e;
}

.post-likes-zone {
    position: relative;
    padding-bottom: 0;
    overflow: visible;
}

.post-likes-zone .post-actions {
    padding: 0;
    align-items: center;
    gap: 0.5rem;
}

.post-likes-zone .post-actions-start {
    display: flex;
    align-items: center;
}

.post-likes-zone .post-actions .like-btn,
.post-likes-zone .post-actions .share-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    vertical-align: middle;
}

.post-likes-zone .post-actions .share-btn {
    width: 1.25rem;
    height: 1.25rem;
    font-size: 1.25rem;
}

.post-likes-zone .post-actions .share-btn i,
.post-likes-zone .post-actions .share-btn .ph {
    font-size: 1.25rem;
    line-height: 1;
    display: block;
}

.post-likes-zone.has-likers .post-like-count,
.post-likes-zone.has-likers .like-btn {
    cursor: pointer;
}

.post-likers-popover {
    position: absolute;
    left: 16px;
    bottom: 100%;
    margin-bottom: 6px;
    min-width: 180px;
    max-width: 260px;
    padding: 10px 12px;
    background: #fff;
    border: 1px solid #dbdbdb;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    font-size: 0.8rem;
    line-height: 1.45;
    z-index: 50;
    pointer-events: auto;
}

.post-likers-popover.is-visible {
    display: block !important;
}

.post-likers-popover a {
    color: #262626;
    font-weight: 600;
    text-decoration: none;
}

.post-likers-popover .post-likers-more {
    color: #8e8e8e;
    font-weight: 400;
}

.like-btn,
.share-btn,
.comment-like-btn {
    border: none;
    background: none;
    padding: 0;
    color: #262626;
    line-height: 1;
}

.post-likes-zone .like-btn {
    font-size: 0.85rem;
}

.share-btn {
    appearance: none;
    -webkit-appearance: none;
    box-shadow: none;
    outline: none;
    opacity: 0.5;
}

.share-btn:hover,
.share-btn:focus,
.share-btn:focus-visible,
.share-btn:active {
    color: #525252;
    border: none;
    outline: none;
    box-shadow: none;
    opacity: 1;
}

.post-share-menu {
    min-width: 8.5rem;
    font-size: 0.875rem;
    border: none;
    padding: 0.2rem 0;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.post-share-menu .dropdown-item {
    cursor: pointer;
    border: none;
    background: none;
    box-shadow: none;
}

.post-share-menu .dropdown-item:hover,
.post-share-menu .dropdown-item:focus,
.post-share-menu .dropdown-item:active,
.post-share-menu .dropdown-item:focus-visible {
    border: none;
    outline: none;
    box-shadow: none;
}

.post-share-toast {
    position: fixed;
    left: 50%;
    bottom: 1.25rem;
    transform: translateX(-50%) translateY(0.5rem);
    padding: 0.45rem 0.85rem;
    border-radius: 999px;
    background: rgba(22, 24, 28, 0.92);
    color: #fff;
    font-size: 0.8rem;
    line-height: 1.2;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease, transform 0.2s ease;
    z-index: 1080;
}

.post-share-toast.is-visible {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.comment-like-btn {
    font-size: 0.85rem;
    appearance: none;
    -webkit-appearance: none;
    box-shadow: none;
    outline: none;
    vertical-align: middle;
}

.comment-like-btn:focus {
    outline: none;
    box-shadow: none;
}

.like-btn.liked,
.comment-like-btn.liked {
    color: var(--ps-like);
}

.post-like-count:not(.is-zero) {
    cursor: pointer;
}

.comment-like-count:not(.is-zero) {
    color: var(--ps-like);
    font-weight: 600;
}

.comment-like-count.is-zero {
    display: none;
}

.comment-body {
    line-height: 1.4;
}

.comment-text {
    margin-right: 0.15rem;
}

.comment-like-inline {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    margin-left: 0.25rem;
    vertical-align: baseline;
}

.comment-actions {
    margin-top: 2px;
}

.comment-reply-btn {
    border: none;
    background: none;
    padding: 0;
    font-size: 0.75rem;
    font-weight: 600;
    color: #8e8e8e;
}

.comment-reply-btn:hover {
    color: #262626;
}

.comment-replies {
    margin-left: 1.75rem;
    padding-left: 0.75rem;
    border-left: 2px solid #efefef;
}

.comment-reply .comment-body {
    font-size: 0.95rem;
}

.explore-masonry {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--ps-post-gap);
}

@media (max-width: 768px) {
    .explore-masonry {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

.explore-masonry .explore-item {
    display: block;
    aspect-ratio: 1;
    overflow: hidden;
    border-radius: 8px;
}

.explore-masonry a.explore-item,
.explore-masonry .explore-item a {
    display: block;
    width: 100%;
    height: 100%;
}

.explore-masonry img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.location-field {
    position: relative;
}

#editProfile .modal-content,
#editProfile .modal-body.edit-profile-body {
    overflow: visible;
}

#editProfile .modal-body.edit-profile-body {
    max-height: min(70vh, 36rem);
    overflow-y: auto;
    overflow-x: visible;
}

#editProfile .location-suggestions {
    z-index: 2000;
}

.location-suggestions {
    position: absolute;
    z-index: 20;
    top: calc(100% + 0.2rem);
    left: 0;
    right: 0;
    max-height: 14rem;
    overflow-y: auto;
    border: 1px solid var(--ps-border);
    border-radius: 0.5rem;
    background: #fff;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    padding: 0.25rem;
}

.location-suggestion {
    display: block;
    width: 100%;
    border: none;
    background: transparent;
    text-align: left;
    padding: 0.45rem 0.6rem;
    border-radius: 0.35rem;
    font-size: 0.85rem;
    color: var(--ps-ink);
    cursor: pointer;
}

.location-suggestion:hover,
.location-suggestion.is-active {
    background: var(--ps-primary-tint);
    color: var(--ps-primary);
}

.auth-card {
    max-width: 400px;
    margin: 60px auto;
    background: #fff;
    border: 1px solid #dbdbdb;
    border-radius: 8px;
    padding: 32px;
}

.account-card {
    max-width: 440px;
    margin: 0 auto;
}

.account-feed-prefs {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--ps-border);
}

.account-feed-prefs-first {
    margin-top: 0;
    padding-top: 0;
    border-top: none;
    padding-bottom: 1.5rem;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid var(--ps-border);
}

.account-settings-links {
    margin-bottom: 0;
}

.onboarding-card {
    max-width: 440px;
}

.profile-header-btn {
    --bs-btn-padding-y: 0.125rem;
    --bs-btn-padding-x: 0.5rem;
    --bs-btn-font-size: 0.75rem;
    --bs-btn-line-height: 1.25;
    font-weight: 500;
}

.profile-follow-btn {
    padding: 0;
    font-size: 0.75rem;
    font-weight: 600;
    line-height: 1.25;
    text-decoration: none;
    vertical-align: baseline;
}

.profile-follow-btn-following {
    color: #8e8e8e;
}

.profile-follow-btn-following:hover,
.profile-follow-btn-following:focus-visible {
    color: #525252;
    text-decoration: underline;
}

.profile-stats {
    display: flex;
    gap: 32px;
}

.profile-stat-link,
.profile-stat {
    color: inherit;
    text-decoration: none;
}

.profile-stat-link:hover,
.profile-stat-link:focus-visible {
    color: inherit;
    text-decoration: none;
}

.profile-stat-link:hover strong,
.profile-stat-link:focus-visible strong {
    color: var(--ps-link);
}

.profile-stats strong {
    display: block;
    font-size: 1.1rem;
}

.profile-stats span {
    color: #8e8e8e;
    font-size: 0.85rem;
}

.profile-posts-section {
    scroll-margin-top: 1.25rem;
}

.profile-location,
.profile-shoot-style {
    font-size: 0.9rem;
}

.profile-location-link {
    color: inherit;
    text-decoration: none;
}

.profile-location-link:hover,
.profile-location-link:focus-visible {
    color: inherit;
    text-decoration: underline;
}

.story-upload-page {
    max-width: 520px;
    margin: 0 auto;
}

.story-upload-ring-full {
    padding-bottom: 0.5rem;
}

.story-upload-ring-shell {
    width: min(100%, 420px);
    max-height: calc(100vh - 120px);
    margin: 0 auto;
}

.story-upload-ring-stage {
    max-height: calc(100vh - 120px);
}

@media (max-width: 767px) {
    .story-upload-ring-shell,
    .story-upload-ring-stage {
        width: 100%;
        max-height: min(78vh, 720px);
    }
}

.story-compose-frame {
    width: min(100%, 360px);
    min-height: 520px;
    margin: 0 auto;
    aspect-ratio: 9 / 16;
    background: linear-gradient(180deg, #f8fafb 0%, #eef2f6 100%);
    border: 1px solid #dde3ea;
    border-radius: 18px;
    box-shadow:
        0 1px 0 rgba(255, 255, 255, 0.9) inset,
        0 12px 40px rgba(61, 81, 104, 0.1);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.story-compose-chrome {
    flex-shrink: 0;
    padding: 10px 12px 6px;
}

.story-compose-progress {
    display: flex;
    gap: 4px;
    margin-bottom: 10px;
}

.story-compose-progress span {
    flex: 1;
    height: 3px;
    border-radius: 3px;
    background: rgba(61, 81, 104, 0.12);
}

.story-compose-progress span.is-active {
    background: linear-gradient(90deg, var(--ps-primary) 0%, rgba(61, 81, 104, 0.35) 70%);
}

.story-compose-progress span.is-filled {
    background: var(--ps-primary);
}

.story-compose-progress span.is-disabled {
    opacity: 0.35;
}

.story-upload-ready {
    margin-top: 0.85rem;
    text-align: center;
    font-size: 0.78rem;
    font-weight: 500;
    color: var(--ps-primary);
}

.story-upload-queue {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 0.65rem;
    flex-wrap: wrap;
}

.story-upload-queue-item {
    position: relative;
    width: 52px;
    height: 92px;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid #dde3ea;
    box-shadow: 0 4px 12px rgba(61, 81, 104, 0.08);
}

.story-upload-queue-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.story-upload-queue-remove {
    position: absolute;
    top: 2px;
    right: 2px;
    width: 18px;
    height: 18px;
    border: none;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.55);
    color: #fff;
    font-size: 0.85rem;
    line-height: 1;
    padding: 0;
    cursor: pointer;
}

.story-compose-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.story-compose-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: cover;
    border: 1.5px solid #fff;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
}

.story-compose-avatar.user-avatar-icon {
    --shutter-glyph: 18px;
    object-fit: unset;
}

.story-compose-header-text {
    display: flex;
    flex-direction: column;
    line-height: 1.15;
    min-width: 0;
}

.story-compose-username {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--ps-ink);
}

.story-compose-label {
    font-size: 0.65rem;
    color: var(--ps-muted);
    letter-spacing: 0.02em;
}

.story-compose-stage {
    position: relative;
    flex: 1 1 auto;
    min-height: 280px;
    height: 0;
    margin: 0 12px;
    border-radius: 12px;
    overflow: hidden;
    background: #fff;
    border: 1.5px dashed #cfd8e3;
    box-shadow: inset 0 1px 8px rgba(61, 81, 104, 0.04);
}

.story-compose-pick {
    position: absolute;
    inset: 0;
    cursor: pointer;
    transition: background 0.15s ease;
}

.story-compose-pick:hover,
.story-compose-pick:focus-within {
    background: rgba(61, 81, 104, 0.03);
}

.story-compose-pick-overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
}

.story-compose-pick--has-existing .story-compose-pick-overlay {
    background: linear-gradient(
        180deg,
        rgba(255, 255, 255, 0.94) 0%,
        rgba(255, 255, 255, 0.62) 42%,
        rgba(255, 255, 255, 0.72) 100%
    );
}

.story-compose-pick-intro {
    position: absolute;
    top: 0;
    right: 0;
    left: 0;
    padding: 0.85rem 1rem 0;
    text-align: center;
}

.story-compose-pick-heading {
    margin: 0;
    font-size: 1rem;
    font-weight: 700;
    color: var(--ps-ink);
    line-height: 1.2;
}

.story-compose-pick-lead {
    margin: 0.25rem auto 0;
    max-width: 16rem;
    font-size: 0.74rem;
    line-height: 1.4;
    color: var(--ps-muted);
}

.story-compose-pick-slots {
    margin: 0.35rem 0 0;
    font-size: 0.72rem;
    font-weight: 500;
    color: var(--ps-primary);
}

.story-compose-existing-previews {
    position: absolute;
    inset: 0;
    z-index: 0;
    display: flex;
    align-items: stretch;
    justify-content: stretch;
    opacity: 0.3;
    filter: saturate(0.65);
    pointer-events: none;
}

.story-compose-existing-previews img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border: none;
    border-radius: 0;
    box-shadow: none;
}

.story-compose-existing-previews--standalone {
    position: relative;
    width: min(100%, 200px);
    aspect-ratio: 9 / 16;
    margin: 0 auto 0.25rem;
    opacity: 0.38;
    filter: saturate(0.7);
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--ps-border);
}

.story-compose-existing-previews--standalone img {
    width: 100%;
    height: 100%;
}

.story-compose-pick-action {
    position: absolute;
    inset: 0;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.2rem;
    padding: 1rem;
    text-align: center;
    color: var(--ps-muted);
    pointer-events: none;
}

.story-compose-pick-icon {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--ps-primary-tint);
    color: var(--ps-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    margin-bottom: 0.35rem;
}

.story-compose-pick-title {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--ps-ink);
}

.story-compose-pick-hint {
    font-size: 0.72rem;
    color: var(--ps-muted);
}

.story-compose-file-input {
    position: absolute;
    inset: 0;
    z-index: 2;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.story-compose-crop {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
}

.story-compose-crop-inner {
    flex: 1;
    width: 100%;
    height: 100%;
    min-height: 240px;
    max-height: none;
    background: #e9eef3;
    border-radius: 0;
}

.story-compose-crop-inner > img {
    display: block;
    max-width: none;
    width: 100%;
}

.story-compose-crop-inner .cropper-container {
    width: 100% !important;
    height: 100% !important;
}

.story-compose-crop-inner .cropper-wrap-box,
.story-compose-crop-inner .cropper-canvas,
.story-compose-crop-inner .cropper-drag-box {
    width: 100% !important;
    height: 100% !important;
}

.story-compose-crop-inner .cropper-modal {
    background: rgba(233, 238, 243, 0.72);
}

.story-compose-crop-inner .cropper-bg {
    background-color: #e9eef3;
    background-image: none;
}

.story-compose-crop-inner .cropper-view-box {
    outline: 2px solid rgba(255, 255, 255, 0.95);
    outline-offset: -1px;
}

.story-compose-foot {
    flex-shrink: 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.35rem;
    padding: 8px 12px 12px;
}

.story-compose-pill {
    font-size: 0.62rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--ps-primary);
    background: rgba(61, 81, 104, 0.08);
    border: 1px solid rgba(61, 81, 104, 0.1);
    border-radius: 999px;
    padding: 0.2rem 0.55rem;
}

.story-compose-pill-muted {
    color: var(--ps-muted);
    background: rgba(142, 142, 142, 0.08);
    border-color: rgba(142, 142, 142, 0.12);
}

.story-compose-tools {
    display: none;
    margin-top: 1rem;
    padding: 0 0.25rem;
}

.story-compose-tools .crop-toolbar {
    width: 100%;
}

.story-compose-tools .crop-zoom-range {
    min-width: 140px;
    max-width: none;
}

.story-upload-page:has(#crop-step:not(.d-none)) .story-compose-tools {
    display: block;
}

.story-upload-page:has(#crop-step:not(.d-none)) .story-compose-stage {
    border-style: solid;
    border-color: #c5d0dc;
}

.story-upload-page:has(#crop-step:not(.d-none)) .story-compose-helper {
    display: block;
}

.story-compose-helper {
    display: none;
    margin-top: 0.65rem;
}

.story-upload-caption {
    border-radius: 10px;
    background: #f8f9fa;
    border-color: #e5e5e5;
}

.story-upload-caption:focus {
    background: #fff;
}

.story-upload-submit {
    border-radius: 10px;
    padding-top: 0.65rem;
    padding-bottom: 0.65rem;
    font-weight: 600;
    font-size: 1rem;
}

@media (min-width: 768px) {
    .story-compose-frame {
        width: min(100%, 380px);
    }
}

.crop-container {
    width: 100%;
    min-height: 320px;
    max-height: 520px;
    background: #1a1a1a;
    border-radius: 8px;
}

.crop-container-avatar {
    min-height: 240px;
    max-height: 360px;
}

.crop-container-avatar .cropper-container {
    max-height: 360px;
}

.crop-container > img {
    display: block;
    max-width: 100%;
}

.crop-container .cropper-container {
    max-height: 520px;
}

.crop-toolbar .crop-zoom-range {
    min-width: 120px;
    max-width: 220px;
}

.cropper-view-box,
.cropper-face {
    border-radius: 0;
}

.cropper-line,
.cropper-point {
    background-color: #fff;
}

.edit-current-photo {
    width: 100%;
    max-width: 100%;
    height: auto;
    object-fit: cover;
    display: block;
    margin-inline: auto;
}

.stories-top {
    margin-bottom: 0;
}

.stories-bar {
    --stories-ease: cubic-bezier(0.22, 1, 0.36, 1);
    --stories-ease-out: cubic-bezier(0.33, 1, 0.68, 1);
    --stories-duration: 0.52s;
}

.stories-bar > summary {
    list-style: none;
    display: block;
    height: 0.5rem;
    margin-bottom: 0.35rem;
    cursor: pointer;
    position: relative;
    transition: margin-bottom var(--stories-duration) var(--stories-ease);
}

.stories-bar > summary::-webkit-details-marker {
    display: none;
}

.stories-bar > summary::after {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    width: 0.4rem;
    height: 0.4rem;
    margin-left: -0.2rem;
    border-right: 1.5px solid var(--ps-muted, #888);
    border-bottom: 1.5px solid var(--ps-muted, #888);
    transform: rotate(-135deg);
    transition: transform var(--stories-duration) var(--stories-ease-out),
        top var(--stories-duration) var(--stories-ease-out);
}

.stories-bar.is-collapsed > summary::after {
    transform: rotate(45deg);
    top: -0.15rem;
}

.stories-bar.is-collapsed > summary {
    margin-bottom: 0;
}

.stories-scroll-panel {
    display: grid;
    grid-template-rows: 1fr;
    opacity: 1;
    transform: translateY(0);
    transition:
        grid-template-rows var(--stories-duration) var(--stories-ease),
        opacity calc(var(--stories-duration) * 0.85) var(--stories-ease) 0.05s,
        transform var(--stories-duration) var(--stories-ease);
}

.stories-bar.is-collapsed .stories-scroll-panel {
    grid-template-rows: 0fr;
    opacity: 0;
    transform: translateY(-0.3rem);
    pointer-events: none;
    transition:
        grid-template-rows 0.44s cubic-bezier(0.4, 0, 0.2, 1),
        opacity 0.32s cubic-bezier(0.4, 0, 0.2, 1),
        transform 0.44s cubic-bezier(0.4, 0, 0.2, 1);
}

.stories-scroll-panel > .stories-scroll {
    min-height: 0;
    overflow: hidden;
}

.stories-bar:not(.is-collapsed) .stories-scroll {
    overflow-x: auto;
}

.stories-scroll {
    scrollbar-width: thin;
}

@media (prefers-reduced-motion: reduce) {
    .stories-bar > summary,
    .stories-bar > summary::after,
    .stories-scroll-panel {
        transition: none;
    }
}

.story-ring,
.story-ring-btn {
    flex: 0 0 auto;
    width: 72px;
    text-align: center;
}

.story-ring-btn {
    border: none;
    background: transparent;
    padding: 0;
    cursor: pointer;
    color: inherit;
}

.story-shutter {
    --shutter-open: 0.75;
    width: 64px;
    height: 64px;
    margin: 0 auto 4px;
    position: relative;
    display: block;
    border-radius: 50%;
    overflow: visible;
    box-shadow:
        0 2px 10px rgba(0, 0, 0, 0.14),
        inset 0 0 0 1px rgba(255, 255, 255, 0.35);
}

.story-shutter:not(.has-story) {
    --shutter-open: 0.88;
}

.story-shutter:has(.story-ring-edge) {
    margin-top: 3px;
}

@property --story-ring-progress {
    syntax: '<angle>';
    initial-value: 0deg;
    inherits: false;
}

.story-ring-edge {
    --story-ring-progress: 0deg;
    position: absolute;
    inset: -3px;
    border-radius: 50%;
    pointer-events: none;
    z-index: 6;
    opacity: 0;
    padding: 2.5px;
    background: conic-gradient(
        from -90deg,
        var(--ps-primary) 0deg,
        #b07d62 var(--story-ring-progress),
        var(--ps-link) var(--story-ring-progress),
        transparent var(--story-ring-progress),
        transparent 360deg
    );
    -webkit-mask:
        linear-gradient(#fff 0 0) content-box,
        linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask:
        linear-gradient(#fff 0 0) content-box,
        linear-gradient(#fff 0 0);
    mask-composite: exclude;
}

.story-ring-unseen .story-ring-edge {
    opacity: 1;
    --story-ring-progress: 360deg;
}

.story-ring-animate .story-ring-edge {
    opacity: 1;
    animation: story-ring-draw 3.6s ease-in-out 1 forwards;
}

@keyframes story-ring-draw {
    from {
        --story-ring-progress: 0deg;
    }

    to {
        --story-ring-progress: 360deg;
    }
}

.story-ring.viewed .story-ring-edge {
    opacity: 0;
    visibility: hidden;
}

@media (prefers-reduced-motion: reduce) {
    .story-ring-animate .story-ring-edge {
        animation: none;
        --story-ring-progress: 360deg;
    }
}

.story-shutter-hole {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    overflow: hidden;
    background: #eceef1;
    z-index: 1;
}

.story-shutter-avatar {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.story-shutter-glass {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    pointer-events: none;
    z-index: 3;
    opacity: calc(0.55 + (1 - var(--shutter-open)) * 0.45);
    background:
        radial-gradient(circle at 32% 28%, rgba(255, 255, 255, 0.34) 0%, transparent 48%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.16) 0%, rgba(0, 0, 0, 0.1) 100%);
}

.story-shutter::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.88);
    box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.12);
    z-index: 4;
    pointer-events: none;
}

.story-shutter.viewed .story-shutter-avatar,
.story-ring.viewed .story-shutter-avatar {
    filter: grayscale(0.9) brightness(0.82) saturate(0.75);
}

.story-username {
    font-size: 0.7rem;
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.story-ring-own .story-username {
    font-size: 0.625rem;
    line-height: 1.2;
    white-space: normal;
    overflow: visible;
    text-overflow: unset;
}

body.story-lightbox-open {
    overflow: hidden;
}

.story-lightbox[hidden] {
    display: none !important;
}

.story-lightbox {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.28s ease, visibility 0.28s ease;
}

.story-lightbox.is-open {
    opacity: 1;
    visibility: visible;
}

.story-lightbox-backdrop {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 80% 60% at 50% 45%, rgba(0, 0, 0, 0.55) 0%, rgba(0, 0, 0, 0.88) 100%),
        rgba(0, 0, 0, 0.78);
    backdrop-filter: blur(16px) saturate(1.1);
    -webkit-backdrop-filter: blur(16px) saturate(1.1);
}

.story-lightbox-dismiss {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 2;
    width: 44px;
    height: 44px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.9);
    display: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.15s ease, transform 0.15s ease;
}

.story-lightbox-dismiss:hover {
    background: rgba(255, 255, 255, 0.18);
    transform: scale(1.04);
}

@media (min-width: 768px) {
    .story-lightbox-dismiss {
        display: flex;
    }
}

.story-lightbox-shell {
    position: relative;
    z-index: 1;
    width: min(100vw - 32px, 420px);
    max-height: calc(100vh - 48px);
    transform: scale(0.94) translateY(12px);
    transition: transform 0.32s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.32s ease;
}

.story-lightbox.is-open .story-lightbox-shell {
    transform: scale(1) translateY(0);
}

.story-lightbox-shell.anim-handoff-out {
    opacity: 0;
    transform: scale(0.92) translateY(8px);
    transition: transform 0.34s cubic-bezier(0.4, 0, 1, 1), opacity 0.34s ease;
}

.story-lightbox-shell.anim-handoff-in {
    animation: storyHandoffIn 0.38s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes storyHandoffIn {
    from {
        opacity: 0;
        transform: scale(0.94) translateX(28px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateX(0);
    }
}

.story-queue-hint {
    margin: 14px 0 0;
    text-align: center;
    color: rgba(255, 255, 255, 0.55);
    font-size: 0.75rem;
    letter-spacing: 0.02em;
}

.story-lightbox-stage {
    position: relative;
    background: #0a0a0a;
    border-radius: 16px;
    overflow: hidden;
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.08),
        0 24px 80px rgba(0, 0, 0, 0.65),
        0 8px 24px rgba(0, 0, 0, 0.4);
    aspect-ratio: 9 / 16;
    max-height: calc(100vh - 48px);
    display: flex;
    flex-direction: column;
}

.story-lightbox-stage::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: min(34vh, 200px);
    background: linear-gradient(
        180deg,
        rgba(0, 0, 0, 0.78) 0%,
        rgba(0, 0, 0, 0.52) 24%,
        rgba(0, 0, 0, 0.28) 50%,
        rgba(0, 0, 0, 0.1) 72%,
        transparent 100%
    );
    pointer-events: none;
    z-index: 3;
}

.story-lightbox-stage.is-loading .story-media-wrap {
    opacity: 0.35;
}

.story-lightbox-stage.anim-slide-in .story-slide-image {
    animation: storySlideIn 0.28s ease;
}

@keyframes storySlideIn {
    from { opacity: 0.4; transform: scale(1.02); }
    to { opacity: 1; transform: scale(1); }
}

.story-progress-bars {
    display: flex;
    gap: 4px;
    padding: 10px 12px 0;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 4;
}

.story-progress-track {
    flex: 1;
    height: 3px;
    background: rgba(255, 255, 255, 0.22);
    border-radius: 3px;
    overflow: hidden;
    box-shadow: 0 0 0 0.5px rgba(0, 0, 0, 0.2);
}

.story-progress-fill {
    height: 100%;
    width: 0;
    background: #fff;
    border-radius: 3px;
    box-shadow: 0 0 6px rgba(255, 255, 255, 0.35);
}

.story-lightbox-header {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    padding: 26px 12px 10px;
    z-index: 4;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    background: transparent;
}

.story-header-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    border: 1.5px solid rgba(255, 255, 255, 0.9);
    flex-shrink: 0;
}

.story-header-avatar.user-avatar-icon {
    --shutter-glyph: 20px;
    object-fit: unset;
    background: #eceef1;
    color: #d5d9de;
}

.story-user-name {
    color: #fff;
    font-weight: 600;
    font-size: 0.875rem;
    text-decoration: none;
    display: block;
    line-height: 1.2;
}

.story-user-name:hover {
    color: #fff;
    text-decoration: underline;
}

.story-time-ago {
    display: block;
    color: rgba(255, 255, 255, 0.65);
    font-size: 0.7rem;
}

.story-icon-btn {
    width: 36px;
    height: 36px;
    border: none;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.15s ease;
}

.story-icon-btn:hover {
    background: rgba(255, 255, 255, 0.22);
}

a.story-icon-btn {
    text-decoration: none;
    color: #fff;
}

.story-icon-btn-add {
    background: rgba(255, 255, 255, 0.12);
}

.story-icon-btn-add:hover {
    background: rgba(255, 255, 255, 0.22);
    color: #fff;
}

.story-lightbox-stage.is-own .story-add-overlay {
    position: absolute;
    bottom: 12px;
    right: 12px;
    z-index: 6;
    pointer-events: auto;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.14);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    color: rgba(255, 255, 255, 0.92);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    text-decoration: none;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.18);
    transition: background 0.15s ease, color 0.15s ease;
}

.story-lightbox-stage.is-own .story-add-overlay:hover {
    background: rgba(255, 255, 255, 0.24);
    color: #fff;
}

.story-media-wrap {
    flex: 1;
    position: relative;
    display: flex;
    align-items: stretch;
    min-height: 0;
    transition: opacity 0.2s ease;
}

.story-media-frame {
    flex: 1;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #000;
}

.story-slide-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    user-select: none;
}

.story-caption {
    position: absolute;
    bottom: 68px;
    left: 0;
    right: 0;
    padding: 0 16px 10px;
    margin: 0;
    color: rgba(255, 255, 255, 0.96);
    font-size: 0.9rem;
    line-height: 1.45;
    background: none;
    text-shadow:
        0 1px 2px rgba(0, 0, 0, 0.65),
        0 4px 18px rgba(0, 0, 0, 0.45);
    pointer-events: none;
    z-index: 2;
}

.story-footer {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 5;
    padding: 12px 14px calc(14px + env(safe-area-inset-bottom, 0px));
    background: transparent;
    pointer-events: none;
}

.story-footer::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: min(42vh, 220px);
    background: linear-gradient(
        0deg,
        rgba(0, 0, 0, 0.78) 0%,
        rgba(0, 0, 0, 0.52) 22%,
        rgba(0, 0, 0, 0.28) 48%,
        rgba(0, 0, 0, 0.1) 72%,
        transparent 100%
    );
    pointer-events: none;
    z-index: -1;
}

.story-footer::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: min(28vh, 140px);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    mask-image: linear-gradient(0deg, #000 0%, #000 18%, transparent 100%);
    -webkit-mask-image: linear-gradient(0deg, #000 0%, #000 18%, transparent 100%);
    pointer-events: none;
    z-index: -1;
}

.story-footer-viewer,
.story-footer-owner {
    position: relative;
    z-index: 1;
    pointer-events: auto;
}

.story-footer-viewer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.65rem;
}

.story-footer-viewer .story-reply-status {
    flex: 1 1 100%;
    order: 3;
}

.story-like-inline {
    flex: 0 0 auto;
}

.story-footer-viewer .story-like-inline .comment-like-btn {
    color: #fff;
    font-size: 1.1rem;
}

.story-like-btn {
    border: none;
    background: transparent;
    line-height: 1;
    padding: 0.15rem 0.1rem;
    cursor: pointer;
}

.story-like-btn.liked,
.story-footer-viewer .story-like-inline .comment-like-btn.liked {
    color: var(--ps-like);
}

.story-footer-viewer .story-like-inline .comment-like-count:not(.is-zero) {
    color: #fff;
    font-weight: 600;
}

.story-footer-viewer .story-like-inline .comment-like-btn.liked + .comment-like-count:not(.is-zero) {
    color: var(--ps-like);
}

.story-reply-form {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 0.45rem;
    min-width: 0;
}

.story-reply-input {
    flex: 1;
    min-width: 0;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
    font-size: 0.85rem;
    padding: 0.5rem 0.9rem;
    outline: none;
    transition:
        border-color 0.22s ease,
        background 0.22s ease,
        box-shadow 0.22s ease;
}

.story-reply-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.story-reply-input:focus {
    border-color: rgba(255, 255, 255, 0.42);
    background: rgba(255, 255, 255, 0.12);
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.08);
}

.story-reply-input-blocked {
    animation: storyReplyGuard 0.55s ease;
}

.story-reply-guard-active .story-footer-viewer .story-reply-input {
    border-color: rgba(176, 125, 98, 0.65);
    box-shadow: 0 0 0 3px rgba(176, 125, 98, 0.22);
}

@keyframes storyReplyGuard {
    0%, 100% { transform: translateX(0); }
    20% { transform: translateX(-4px); }
    40% { transform: translateX(4px); }
    60% { transform: translateX(-3px); }
    80% { transform: translateX(3px); }
}

.story-reply-send {
    flex: 0 0 auto;
    border: none;
    background: transparent;
    color: rgba(255, 255, 255, 0.88);
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.25rem 0.15rem;
    cursor: pointer;
    transition: color 0.2s ease, opacity 0.2s ease;
}

.story-reply-send:hover:not(:disabled) {
    color: #fff;
}

.story-reply-send:disabled {
    opacity: 0.45;
    cursor: default;
}

.story-reply-form.is-sending .story-reply-input {
    opacity: 0.7;
}

.story-reply-form.is-sent .story-reply-input {
    border-color: rgba(176, 125, 98, 0.55);
}

.story-reply-form.is-sent .story-reply-send {
    color: var(--ps-like);
}

.story-reply-form.is-error .story-reply-input {
    border-color: rgba(220, 80, 80, 0.65);
}

.story-reply-status {
    margin: 0;
    font-size: 0.72rem;
    font-weight: 600;
    line-height: 1.3;
    text-align: center;
    padding-top: 0.15rem;
}

.story-reply-status.is-success {
    color: var(--ps-like);
}

.story-reply-status.is-error {
    color: #f3b5b5;
}

.story-footer-owner {
    display: flex;
    justify-content: center;
}

.story-owner-stats {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.35rem;
}

.story-view-count {
    font-size: 0.68rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.42);
    letter-spacing: 0.01em;
}

.story-insights-view-count {
    font-weight: 500;
    color: rgba(255, 255, 255, 0.45);
}

.story-insights-btn {
    border: none;
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.95);
    font-size: 0.78rem;
    font-weight: 600;
    padding: 0.45rem 0.95rem;
    border-radius: 999px;
    cursor: pointer;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.18);
    transition: background 0.2s ease, transform 0.2s ease;
}

.story-insights-btn:hover {
    background: rgba(255, 255, 255, 0.18);
}

.story-insights-btn:active {
    transform: scale(0.98);
}

.story-delete-confirm {
    position: absolute;
    inset: 0;
    z-index: 12;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.25rem;
    background: rgba(0, 0, 0, 0.62);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    animation: storyDeleteConfirmIn 0.22s ease-out;
}

.story-lightbox-stage.is-delete-confirm-open .story-progress-bars,
.story-lightbox-stage.is-delete-confirm-open .story-lightbox-header,
.story-lightbox-stage.is-delete-confirm-open .story-media-wrap,
.story-lightbox-stage.is-delete-confirm-open .story-footer {
    filter: blur(2px);
    pointer-events: none;
}

@keyframes storyDeleteConfirmIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.story-delete-confirm-card {
    width: min(100%, 280px);
    padding: 1.35rem 1.25rem 1.15rem;
    border-radius: 16px;
    background: rgba(18, 18, 18, 0.96);
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.55);
    text-align: center;
}

.story-delete-confirm-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    margin-bottom: 0.65rem;
    border-radius: 999px;
    background: rgba(220, 53, 69, 0.18);
    color: #ff6b7a;
    font-size: 1.15rem;
}

.story-delete-confirm-title {
    margin: 0 0 0.45rem;
    color: #fff;
    font-size: 1.05rem;
    font-weight: 600;
}

.story-delete-confirm-message {
    margin: 0;
    color: rgba(255, 255, 255, 0.72);
    font-size: 0.82rem;
    line-height: 1.45;
}

.story-delete-confirm-preview {
    margin: 0.75rem 0 0;
    padding: 0.55rem 0.65rem;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.06);
    color: rgba(255, 255, 255, 0.88);
    font-size: 0.8rem;
    line-height: 1.4;
    font-style: italic;
}

.story-delete-confirm-actions {
    display: flex;
    gap: 0.55rem;
    margin-top: 1.1rem;
}

.story-delete-confirm-btn {
    flex: 1;
    border: none;
    border-radius: 999px;
    padding: 0.55rem 0.85rem;
    font-size: 0.84rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s ease, transform 0.15s ease;
}

.story-delete-confirm-cancel {
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
}

.story-delete-confirm-cancel:hover {
    background: rgba(255, 255, 255, 0.2);
}

.story-delete-confirm-ok {
    background: #dc3545;
    color: #fff;
}

.story-delete-confirm-ok:hover {
    background: #c82333;
}

.story-insights-panel {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    max-height: 55%;
    background: rgba(14, 14, 14, 0.94);
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px 16px 0 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    pointer-events: auto;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    box-shadow: 0 -12px 40px rgba(0, 0, 0, 0.35);
}

.story-insights-panel:not(.d-none) {
    animation: storyInsightsIn 0.34s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes storyInsightsIn {
    from {
        opacity: 0;
        transform: translateY(18px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (prefers-reduced-motion: reduce) {
    .story-insights-panel:not(.d-none) {
        animation: none;
    }

    .story-reply-input,
    .story-reply-send,
    .story-insights-btn {
        transition: none;
    }
}

.story-insights-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 0.85rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.story-insights-title {
    color: #fff;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.story-insights-close {
    width: 28px;
    height: 28px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.story-insights-body {
    overflow-y: auto;
    padding: 0.65rem 0.85rem 0.85rem;
}

.story-insights-section + .story-insights-section {
    margin-top: 0.85rem;
    padding-top: 0.85rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.story-insights-section-title {
    margin: 0 0 0.5rem;
    color: rgba(255, 255, 255, 0.55);
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.story-insights-item {
    display: flex;
    align-items: flex-start;
    gap: 0.55rem;
    padding: 0.35rem 0;
}

.story-insights-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.story-insights-avatar.user-avatar-icon {
    --shutter-glyph: 18px;
    object-fit: unset;
}

.story-insights-meta {
    min-width: 0;
    flex: 1;
}

.story-insights-user {
    color: #fff;
    font-size: 0.82rem;
    font-weight: 600;
    text-decoration: none;
}

.story-insights-user:hover {
    color: #fff;
    text-decoration: underline;
}

.story-insights-text {
    margin: 0.1rem 0 0;
    color: rgba(255, 255, 255, 0.88);
    font-size: 0.82rem;
    line-height: 1.35;
    word-break: break-word;
}

.story-insights-time {
    display: block;
    margin-top: 0.1rem;
    color: rgba(255, 255, 255, 0.45);
    font-size: 0.68rem;
}

.story-insights-empty {
    color: rgba(255, 255, 255, 0.55) !important;
    font-size: 0.82rem;
    text-align: center;
    padding: 0.5rem 0;
}

.story-nav {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 28%;
    border: none;
    background: transparent;
    z-index: 3;
    cursor: pointer;
}

.story-nav::before {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    transition: background 0.2s ease;
}

.story-nav-prev {
    left: 0;
}

.story-nav-prev::before {
    background: linear-gradient(
        90deg,
        rgba(0, 0, 0, 0.58) 0%,
        rgba(0, 0, 0, 0.32) 32%,
        rgba(0, 0, 0, 0.12) 62%,
        transparent 100%
    );
}

.story-nav-next {
    right: 0;
}

.story-nav-next::before {
    background: linear-gradient(
        270deg,
        rgba(0, 0, 0, 0.58) 0%,
        rgba(0, 0, 0, 0.32) 32%,
        rgba(0, 0, 0, 0.12) 62%,
        transparent 100%
    );
}

.story-nav-prev:hover::before {
    background: linear-gradient(
        90deg,
        rgba(0, 0, 0, 0.72) 0%,
        rgba(0, 0, 0, 0.4) 32%,
        rgba(0, 0, 0, 0.16) 62%,
        transparent 100%
    );
}

.story-nav-next:hover::before {
    background: linear-gradient(
        270deg,
        rgba(0, 0, 0, 0.72) 0%,
        rgba(0, 0, 0, 0.4) 32%,
        rgba(0, 0, 0, 0.16) 62%,
        transparent 100%
    );
}

@media (max-width: 767px) {
    .story-lightbox-shell {
        width: 100vw;
        max-height: 100vh;
        border-radius: 0;
    }

    .story-lightbox-stage {
        border-radius: 0;
        max-height: 100vh;
        aspect-ratio: auto;
        height: 100vh;
    }
}

.story-loader {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 5;
    background: rgba(0, 0, 0, 0.25);
}

.admin-body {
    background: #f4f6f8;
}

.admin-sidebar .nav-link {
    color: #495057;
    border-radius: 6px;
}

.admin-sidebar .nav-link.active {
    background: var(--ps-primary);
    color: #fff;
}

.ratio-picker {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
}

.ratio-picker .btn {
    flex: 0 0 auto;
}

.ratio-picker .btn.active {
    background-color: var(--ps-primary);
    border-color: var(--ps-primary);
    color: #fff;
}

.profile-grid .profile-post-item {
    position: relative;
}

.profile-post-actions {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    align-items: center;
    gap: 1.25rem;
    opacity: 0;
    transition: opacity 0.2s ease;
    pointer-events: none;
}

.profile-post-action {
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
    color: #fff;
    font-size: 1.35rem;
    line-height: 1;
    text-decoration: none;
}

.profile-post-action i {
    filter: drop-shadow(0 1px 4px rgba(0, 0, 0, 0.45));
}

.profile-post-item:hover .profile-post-actions {
    opacity: 1;
    pointer-events: auto;
}

.delete-post-form {
    margin: 0;
}

.delete-post-form .dropdown-item {
    width: 100%;
    border: none;
    background: none;
    text-align: left;
}

.btn-primary {
    --bs-btn-bg: var(--ps-primary);
    --bs-btn-border-color: var(--ps-primary);
    --bs-btn-hover-bg: var(--ps-primary-hover);
    --bs-btn-hover-border-color: var(--ps-primary-hover);
    --bs-btn-active-bg: var(--ps-primary-active);
    --bs-btn-active-border-color: var(--ps-primary-active);
    --bs-btn-disabled-bg: var(--ps-primary);
    --bs-btn-disabled-border-color: var(--ps-primary);
}

.btn-outline-primary {
    --bs-btn-color: var(--ps-primary);
    --bs-btn-border-color: var(--ps-primary);
    --bs-btn-hover-bg: var(--ps-primary);
    --bs-btn-hover-border-color: var(--ps-primary);
    --bs-btn-active-bg: var(--ps-primary-hover);
    --bs-btn-active-border-color: var(--ps-primary-hover);
}

.text-primary {
    --bs-text-opacity: 1;
    color: var(--ps-primary) !important;
}

a.text-primary:hover,
a.text-primary:focus,
.btn-link.text-primary:hover,
.btn-link.text-primary:focus {
    color: var(--ps-primary-hover) !important;
}

.like-btn.liked:hover,
.comment-like-btn.liked:hover {
    color: var(--ps-like-hover);
}