/* Author styles. Generated from main.css by tools/split-discovery-css.php. */

body.chaptertrail-site .discovery-author-page {
    padding: 0 0 12px;
}

.discovery-author-body {
    min-height: 100vh;
}

.discovery-author-page {
    width: min(980px, calc(100% - 48px));
    margin: 0 auto;
    padding: 74px 0 96px;
}

.discovery-author-page h1 {
    max-width: 780px;
    margin: 0;
    color: var(--ink);
    font-size: 4.6rem;
    line-height: 0.96;
}

.discovery-author-page .lead {
    max-width: 720px;
    margin: 24px 0 0;
    color: var(--muted);
    font-size: 1.35rem;
}

.author-profile-heading {
    display: flex;
    align-items: center;
    gap: 22px;
    margin-bottom: 24px;
}

.author-profile-avatar {
    display: block;
    width: 112px;
    height: 112px;
    flex: 0 0 112px;
    overflow: hidden;
    border-radius: 999px;
    object-fit: cover;
    background: var(--green);
    color: #ffffff;
}

.author-profile-avatar--initial {
    display: grid;
    place-items: center;
    font-size: 2.8rem;
    font-weight: 900;
}

.author-profile-body {
    max-width: 760px;
    margin-top: 28px;
    color: var(--ink);
    font-size: 1.1rem;
}

.author-profile-social {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 24px;
}

.author-profile-social a {
    padding: 9px 12px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: rgba(255, 255, 255, 0.58);
    text-decoration: none;
    font-weight: 800;
}

.author-profile-links {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 34px;
}

.profile-page {
    width: min(1080px, calc(100% - 48px));
}

.profile-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
    align-items: start;
}

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

.profile-hero {
    position: relative;
    display: block;
    min-height: 360px;
    overflow: hidden;
    border-radius: 8px;
    background: var(--surface-card);
    box-shadow: 0 16px 42px rgba(24, 32, 43, 0.06);
    margin-bottom: 30px;
}

.profile-hero-overlay {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: flex-end;
    gap: 26px;
    min-height: 360px;
    padding: 26px;
}

.profile-avatar {
    display: block;
    flex: 0 0 128px;
    width: 128px;
    height: 128px;
    overflow: hidden;
    border-radius: 999px;
    object-fit: cover;
    background: var(--green);
    color: #ffffff;
}

.profile-avatar--initial {
    display: grid;
    place-items: center;
    font-size: 3rem;
    font-weight: 900;
}

.profile-hero-copy {
    min-width: 0;
}

.profile-hero-copy h1 {
    font-size: clamp(3rem, 8vw, 5rem);
}

.profile-hero-badges {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-left: 10px;
    vertical-align: middle;
}

.profile-hero-badges .user-role-badges {
    margin-left: 0;
}

.profile-hero-quill {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 2;
}

.profile-hero-quill .user-role-badge {
    width: 40px;
    height: 40px;
}

.profile-hero-quill .user-role-badge svg {
    width: 24px;
    height: 24px;
}

.profile-grid {
    display: grid;
    gap: 18px;
}

.profile-panel {
    border-radius: 10px;
    background: var(--surface-card);
    padding: 24px;
    box-shadow: 0 16px 42px rgba(24, 32, 43, 0.06);
}

.profile-panel h2 {
    margin: 0 0 18px;
    color: var(--ink);
    font-size: 1.18rem;
}

.profile-quote {
    margin: 0;
}

.profile-quote p {
    margin: 0;
    color: var(--ink);
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1.35rem;
    line-height: 1.35;
}

.profile-quote footer {
    margin-top: 12px;
    color: var(--muted);
    font-size: 0.9rem;
    font-weight: 800;
}

.profile-custom-panel .managed-rich-text {
    color: var(--ink);
    font-size: 1.05rem;
    line-height: 1.65;
}

.profile-info-list,
.profile-stat-list {
    display: grid;
    gap: 0;
    margin: 0;
}

.profile-info-list div,
.profile-stat-list div {
    display: grid;
    grid-template-columns: minmax(130px, 0.34fr) minmax(0, 1fr);
    gap: 18px;
    padding: 13px 0;
    border-top: 1px solid color-mix(in srgb, var(--ink) 10%, transparent);
}

.profile-info-list div:first-child,
.profile-stat-list div:first-child {
    border-top: 0;
    padding-top: 0;
}

.profile-info-list dt,
.profile-stat-list dt {
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 850;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.profile-info-list dd,
.profile-stat-list dd {
    margin: 0;
    color: var(--ink);
    font-weight: 750;
}

.profile-muted,
.profile-empty {
    color: var(--muted);
}

.profile-panel-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 18px;
}

.profile-panel-heading h2 {
    margin: 0;
}

.profile-panel-heading a,
.profile-fiction-row h3 a {
    color: var(--blue);
    text-decoration: none;
    font-weight: 850;
}

.profile-fiction-list {
    display: grid;
    gap: 14px;
}

.profile-fiction-row {
    display: grid;
    grid-template-columns: 76px minmax(0, 1fr);
    gap: 16px;
    align-items: start;
}

.profile-fiction-row img {
    display: block;
    width: 76px;
    aspect-ratio: 2 / 3;
    border-radius: 6px;
    object-fit: cover;
}

.profile-fiction-row h3 {
    margin: 0;
    color: var(--ink);
}

.profile-fiction-row p {
    margin: 6px 0;
    color: var(--muted);
}

.profile-fiction-row small {
    color: var(--muted);
    font-weight: 800;
}

.author-work-card {
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr);
    gap: 18px;
    align-items: start;
}

.author-work-card,
.author-empty-state {
    border: 1px solid rgba(23, 32, 38, 0.13);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.72);
    padding: 22px;
}

.author-work-card__cover {
    display: block;
    width: 220px;
    overflow: hidden;
    border-radius: 6px;
    background: #1f2a35;
}

.author-work-card__cover img {
    display: block;
    width: 100%;
    aspect-ratio: 2 / 3;
    object-fit: cover;
}

.author-work-card h2,
.author-empty-state h2 {
    margin: 0;
    color: var(--ink);
}

.author-work-card h2 a {
    color: inherit;
    text-decoration: none;
}

.author-work-card h3 {
    margin: 4px 0 0;
    color: var(--muted);
    font-size: 1rem;
}

.author-work-card p:last-child,
.author-empty-state p:last-child {
    margin-bottom: 0;
}

.author-work-card__meta {
    color: var(--muted);
    font-weight: 800;
}

@media (max-width: 900px) {
.profile-layout,
    .profile-info-list div,
    .profile-stat-list div,
    .profile-fiction-row {
        grid-template-columns: 1fr;
    }

.author-profile-heading {
        flex-direction: column;
        align-items: flex-start;
    }
}

@media (max-width: 760px) {
.discovery-author-page,
    .profile-page {
        width: 100%;
        padding: 0 0 48px;
    }

.author-profile-heading {
        flex-direction: column;
        align-items: flex-start;
    }

.profile-avatar {
        flex-basis: 96px;
        width: 96px;
        height: 96px;
    }

.profile-panel {
        padding: 20px;
    }
}

.profile-hero.has-banner {
    background: #1f2a35;
    box-shadow: none;
}

.profile-banner-image {
    position: absolute;
    inset: 0;
    z-index: 0;
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.profile-hero.has-banner::after {
    position: absolute;
    inset: 0;
    z-index: 1;
    content: "";
    background: linear-gradient(180deg, rgba(12, 20, 30, 0.06), rgba(12, 20, 30, 0.78));
    pointer-events: none;
}

.profile-hero.has-banner .profile-avatar {
    position: relative;
    z-index: 2;
}

.profile-hero.has-banner .profile-hero-copy,
.profile-hero.has-banner .profile-hero-copy h1,
.profile-hero.has-banner .profile-hero-copy .lead {
    color: #ffffff;
}

@media (max-width: 760px) {
    .profile-hero,
    .profile-hero-overlay {
        min-height: 300px;
    }

    .profile-hero-overlay {
        flex-direction: column;
        align-items: flex-start;
        justify-content: flex-end;
        gap: 12px;
        padding: 18px;
    }

    .profile-hero-quill {
        top: 10px;
        right: 10px;
    }

    .profile-hero-quill .user-role-badge {
        width: 34px;
        height: 34px;
    }

    .author-work-card {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .author-work-card__cover {
        width: min(220px, 100%);
    }

    .author-work-card__synopsis.is-collapsible:not(.is-expanded),
    .profile-fiction-copy .is-collapsible:not(.is-expanded) {
        display: -webkit-box;
        overflow: hidden;
        -webkit-box-orient: vertical;
        -webkit-line-clamp: 5;
    }

    .author-work-card__more,
    .cover-card__more {
        display: inline-flex;
        width: max-content;
        padding: 0;
        border: 0;
        background: none;
        color: var(--green);
        cursor: pointer;
        font: inherit;
        font-size: 0.9rem;
        font-weight: 850;
    }
}

.author-work-card__more,
.cover-card__more {
    display: none;
}

/* Profile and fiction shelves use cover cards with details that pull over the cover. */
.profile-fiction-list,
.author-work-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, 220px);
    gap: 18px;
    align-items: start;
}

.profile-fiction-row,
.author-work-card {
    position: relative;
    display: block;
    isolation: isolate;
    width: 220px;
    max-width: 100%;
    min-width: 0;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    padding: 0;
    border: 1px solid rgba(23, 32, 38, 0.13);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.72);
    box-shadow: 0 14px 34px rgba(24, 32, 43, 0.05);
}

.profile-fiction-cover,
.author-work-card__cover {
    position: absolute;
    inset: 0;
    display: block;
    width: auto;
    overflow: hidden;
    border-radius: 10px;
    background: #1f2a35;
}

.profile-fiction-row img,
.author-work-card__cover img {
    display: block;
    width: 100%;
    height: 100%;
    aspect-ratio: auto;
    object-fit: cover;
}

.fiction-peek-card__bottom {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 2;
    display: grid;
    gap: 4px;
    padding: 44px 12px 12px;
    background: linear-gradient(180deg, rgba(10, 16, 24, 0), rgba(10, 16, 24, 0.82) 54%, rgba(10, 16, 24, 0.96));
    color: #ffffff;
    pointer-events: none;
}

.fiction-peek-card__bottom strong {
    overflow: hidden;
    color: #ffffff;
    font-size: 0.94rem;
    font-weight: 900;
    line-height: 1.2;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.fiction-peek-card__rating {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: #62b7ff;
    font-size: 0.8rem;
    font-weight: 850;
    line-height: 1;
}

.fiction-peek-card__rating--empty {
    color: rgba(255, 255, 255, 0.68);
}

.fiction-peek-card__count {
    color: rgba(255, 255, 255, 0.78);
}

.profile-fiction-copy,
.author-work-card__copy {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 1%;
    z-index: 4;
    display: flex;
    width: auto;
    flex-direction: column;
    gap: 8px;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: 14px;
    border: 1px solid rgba(255, 255, 255, 0.48);
    background: rgba(255, 253, 248, 0.58);
    box-shadow:
        0 20px 44px rgba(24, 32, 43, 0.18),
        inset 0 1px 0 rgba(255, 255, 255, 0.62);
    backdrop-filter: blur(18px) saturate(150%);
    -webkit-backdrop-filter: blur(18px) saturate(150%);
    opacity: 1;
    pointer-events: none;
    transform: translateX(100%);
    transition: transform 180ms ease;
}

.profile-fiction-row:hover,
.profile-fiction-row:focus-within,
.author-work-card:hover,
.author-work-card:focus-within {
    z-index: 8;
}

.profile-fiction-row:hover .profile-fiction-copy,
.profile-fiction-row:focus-within .profile-fiction-copy,
.author-work-card:hover .author-work-card__copy,
.author-work-card:focus-within .author-work-card__copy {
    pointer-events: auto;
    transform: translateX(0);
}

.author-empty-state {
    grid-column: 1 / -1;
}

@media (max-width: 1180px) {
    .profile-fiction-list,
    .author-work-list {
        grid-template-columns: repeat(auto-fill, 220px);
    }
}

@media (max-width: 900px) {
    .profile-fiction-list,
    .author-work-list {
        grid-template-columns: repeat(auto-fill, 220px);
    }
}

@media (max-width: 760px) {
    .profile-fiction-list,
    .author-work-list {
        grid-template-columns: 1fr;
    }

    .profile-fiction-row,
    .author-work-card {
        display: grid;
        width: 100%;
        grid-template-columns: 1fr;
        aspect-ratio: auto;
    }

    .profile-fiction-cover,
    .author-work-card__cover {
        position: relative;
        inset: auto;
        width: 100%;
    }

    .profile-fiction-row img,
    .author-work-card__cover img {
        height: auto;
        aspect-ratio: 2 / 3;
    }

    .profile-fiction-copy,
    .author-work-card__copy {
        position: static;
        width: auto;
        max-height: none;
        border: 0;
        border-top: 1px solid var(--line);
        border-radius: 0;
        box-shadow: none;
        pointer-events: auto;
        transform: none;
    }
}

.profile-edit-bar {
    position: sticky;
    top: 62px;
    z-index: 12;
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 12px;
    margin-bottom: 16px;
    padding: 12px 14px;
    border: 1px solid color-mix(in srgb, var(--ink) 12%, transparent);
    border-radius: 10px;
    background: color-mix(in srgb, var(--surface-card) 92%, transparent);
    backdrop-filter: blur(14px);
    box-shadow: 0 12px 32px rgba(24, 32, 43, 0.08);
}

.profile-edit-bar__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-left: auto;
}

.profile-hero-actions {
    margin-left: auto;
    align-self: flex-end;
    flex: 0 0 auto;
}

.profile-hero-edit {
    margin-bottom: 30px;
}

.profile-hero-edit .profile-hero {
    margin-bottom: 0;
}

.profile-edit-cover-actions {
    position: absolute;
    top: 14px;
    left: 14px;
    z-index: 4;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.profile-edit-cover-btn,
.profile-edit-photo-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 0;
    padding: 8px 12px;
    border: 0;
    border-radius: 999px;
    background: rgba(12, 20, 30, 0.78);
    color: #ffffff;
    font: inherit;
    font-size: 0.82rem;
    font-weight: 850;
    cursor: pointer;
}

.profile-edit-cover-btn--quiet {
    background: rgba(12, 20, 30, 0.5);
}

.profile-avatar-edit {
    position: relative;
    z-index: 3;
    display: block;
    flex: 0 0 128px;
    width: 128px;
    height: 128px;
    overflow: hidden;
    border-radius: 999px;
    cursor: pointer;
}

.profile-avatar-edit .profile-avatar {
    position: relative;
    z-index: 0;
    flex: none;
    width: 100%;
    height: 100%;
}

.profile-edit-photo-btn {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 1;
    justify-content: center;
    border-radius: 0;
    padding: 8px 6px 10px;
    font-size: 0.72rem;
}

.profile-edit-saying,
.profile-edit-title,
.profile-edit-body,
.profile-edit-quote,
.profile-edit-attribution,
.profile-edit-bio,
.profile-edit-socials input {
    width: 100%;
    max-width: 100%;
    margin: 0;
    padding: 10px 12px;
    border: 1px solid color-mix(in srgb, var(--ink) 16%, transparent);
    border-radius: 8px;
    background: color-mix(in srgb, var(--surface-strong) 88%, transparent);
    color: inherit;
    font: inherit;
}

.profile-hero.has-banner .profile-edit-saying,
.profile-hero.has-banner .profile-edit-socials input {
    border-color: rgba(255, 255, 255, 0.35);
    background: rgba(12, 20, 30, 0.42);
    color: #ffffff;
}

.profile-hero.has-banner .profile-edit-saying::placeholder,
.profile-hero.has-banner .profile-edit-socials input::placeholder {
    color: rgba(255, 255, 255, 0.72);
}

.profile-edit-saying {
    margin-top: 24px;
}

.profile-edit-socials {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-top: 16px;
}

.profile-edit-socials label {
    display: grid;
    gap: 4px;
    color: inherit;
    font-size: 0.72rem;
    font-weight: 850;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.profile-edit-field {
    display: grid;
    gap: 8px;
    margin: 0 0 12px;
}

.profile-edit-title {
    font-size: 1.18rem;
    font-weight: 800;
}

.profile-edit-quote {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1.35rem;
    line-height: 1.35;
}

.profile-edit-bio {
    min-height: 160px;
    resize: vertical;
}

.profile-crop-stage {
    display: none;
    gap: 12px;
    margin-top: 12px;
}

.profile-crop-stage.is-open {
    display: grid;
}

.profile-crop-stage .button {
    justify-self: start;
}

.profile-crop-stage[data-crop-panel="avatar"] .avatar-cropper {
    width: min(420px, 100%);
}

.profile-crop-stage[data-crop-panel="banner"] .banner-cropper {
    width: auto;
    max-width: 100%;
}

.profile-crop-stage[data-crop-panel="banner"] .banner-cropper img {
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: min(72vh, 720px);
    object-fit: unset;
}

.profile-block {
    display: grid;
    gap: 0;
}

.profile-block-chrome {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 8px;
}

.profile-block-chrome__label {
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 850;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.profile-edit-limit {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    max-width: none;
    margin: 0;
}

.profile-edit-limit input {
    width: 4.5rem;
    min-width: 0;
}

.profile-block.is-profile-block-hidden .profile-panel {
    opacity: 0.48;
}

.profile-page.is-editing .profile-grid {
    gap: 28px;
}

@media (max-width: 760px) {
    .profile-edit-bar {
        top: 54px;
        align-items: stretch;
    }

    .profile-edit-bar__actions {
        margin-left: 0;
    }

    .profile-hero-actions {
        margin-left: 0;
        width: 100%;
    }

    .profile-hero-actions .button {
        width: 100%;
        justify-content: center;
    }

    .profile-avatar-edit {
        flex-basis: 96px;
        width: 96px;
        height: 96px;
    }

    .profile-edit-socials {
        grid-template-columns: 1fr;
    }
}
