body {
    min-height: 100vh;
}

.account-sidebar .account-avatar.profile-img {
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 42, 133, 0.12);
    color: var(--primary);
    font-size: 1.9rem;
    overflow: hidden;
}

.account-sidebar .account-avatar.profile-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.account-grid-top {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
    gap: 24px;
}

.account-hero-card h3 {
    margin: 0 0 12px;
    font-size: 2rem;
    letter-spacing: -0.05em;
}

.account-hero-card p,
.account-resource-meta,
.resource-body p {
    color: var(--text-dim);
    line-height: 1.8;
}

.hero-tag {
    display: inline-flex;
    align-items: center;
    padding: 10px 18px;
    border-radius: 999px;
    background: rgba(255, 42, 133, 0.1);
    border: 1px solid rgba(255, 42, 133, 0.22);
    color: var(--primary);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    margin-bottom: 20px;
}

.account-summary-card h3 {
    margin-top: 0;
    margin-bottom: 16px;
}

.account-metric {
    padding: 18px 20px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.account-metric strong {
    display: block;
    font-size: 3rem;
    font-weight: 900;
    letter-spacing: -0.06em;
}

.account-metric span {
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 0.14em;
    font-size: 0.78rem;
}

.resources-list {
    display: grid;
    gap: 20px;
}

.resource-card,
.empty-state {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 24px;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.22);
}

.resource-card {
    display: grid;
    grid-template-columns: 150px minmax(0, 1fr);
    gap: 20px;
    align-items: stretch;
    padding: 22px;
    cursor: pointer;
    transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.resource-card:hover,
.resource-card:focus-visible {
    transform: translateY(-4px);
    border-color: rgba(255, 42, 133, 0.28);
    box-shadow: 0 28px 70px rgba(0, 0, 0, 0.28);
    outline: none;
}

.resource-image,
.resource-image-empty {
    width: 150px;
    height: 150px;
    border-radius: 18px;
}

.resource-image {
    object-fit: cover;
}

.resource-image-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-dim);
    border: 1px dashed rgba(255, 255, 255, 0.08);
}

.resource-body {
    min-height: 150px;
    display: grid;
    grid-template-rows: auto auto 1fr;
    gap: 8px;
}

.resource-body h3 {
    margin: 2px 0 0;
    font-size: 1.35rem;
    line-height: 1.15;
    letter-spacing: -0.04em;
}

.resource-body p {
    margin: 0;
    max-width: 72ch;
}

.resource-meta {
    display: grid;
    align-content: start;
    gap: 14px;
    height: 100%;
    margin-top: 8px;
}

.resource-files {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.resource-file-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: 999px;
    background: rgba(255, 42, 133, 0.1);
    border: 1px solid rgba(255, 42, 133, 0.14);
    color: white;
    font-size: 0.92rem;
    line-height: 1;
}

.resource-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: flex-end;
    margin-top: auto;
    padding-top: 6px;
}

.account-download-button,
.details-download-button {
    text-decoration: none;
}

.account-download-button {
    min-width: 210px;
    justify-content: center;
    margin-left: auto;
    box-shadow: 0 18px 36px rgba(201, 45, 255, 0.2);
}

.details-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: flex-end;
}

.details-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(0, 0, 0, 0.68);
    backdrop-filter: blur(10px);
    z-index: 14000;
}

.details-card {
    position: relative;
    width: min(1120px, calc(100vw - 36px));
    max-height: calc(100vh - 40px);
    display: grid;
    grid-template-columns: minmax(300px, 0.95fr) minmax(0, 1.05fr);
    gap: 28px;
    padding: 28px;
    border-radius: 30px;
    border: 1px solid rgba(255, 42, 133, 0.2);
    background: rgba(16, 16, 22, 0.97);
    box-shadow: 0 34px 90px rgba(0, 0, 0, 0.48);
    overflow: auto;
}

.details-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 42px;
    height: 42px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.04);
    color: white;
    cursor: pointer;
}

.details-gallery {
    display: grid;
    gap: 14px;
}

.details-main-image-wrap {
    position: relative;
    aspect-ratio: 1 / 1;
    border-radius: 24px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.06);
    background: rgba(255, 255, 255, 0.03);
}

#account-details-main-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: none;
}

.details-main-empty {
    position: absolute;
    inset: 0;
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    color: var(--text-dim);
}

.details-thumbs {
    display: grid;
    grid-template-columns: repeat(auto-fit, 82px);
    gap: 10px;
}

.details-thumb {
    width: 82px;
    height: 82px;
    padding: 0;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.04);
    cursor: pointer;
}

.details-thumb.active {
    border-color: rgba(255, 42, 133, 0.5);
    box-shadow: 0 0 0 2px rgba(255, 42, 133, 0.18);
}

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

.details-content {
    display: grid;
    align-content: start;
    gap: 18px;
}

.details-topline {
    display: flex;
    align-items: center;
    gap: 12px;
    padding-right: 56px;
}

.details-price {
    display: inline-flex;
    padding: 8px 14px;
    border-radius: 999px;
    background: rgba(255, 42, 133, 0.12);
    color: white;
    font-size: 0.92rem;
    font-weight: 800;
}

.details-content h3 {
    margin: 0;
    font-size: clamp(2rem, 4vw, 3rem);
    line-height: 1;
    letter-spacing: -0.05em;
}

.details-description,
.details-section {
    color: var(--text-dim);
    line-height: 1.75;
}

.details-section {
    display: grid;
    gap: 10px;
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    white-space: pre-line;
}

.details-files {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.details-file {
    display: inline-flex;
    align-items: center;
    padding: 10px 14px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: white;
}

.badge {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    padding: 6px 12px;
    border-radius: 999px;
    background: rgba(255, 42, 133, 0.12);
    color: var(--primary);
    font-size: 0.78rem;
    font-weight: 700;
}

.item-tag {
    display: inline-flex;
    padding: 6px 12px;
    border-radius: 999px;
    background: rgba(255, 42, 133, 0.12);
    color: var(--primary);
    font-size: 0.78rem;
    font-weight: 700;
}

.empty-state {
    padding: 30px;
    text-align: center;
    color: var(--text-dim);
}

#account-login-screen {
    position: fixed;
    inset: 0;
    z-index: 12000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(0, 0, 0, 0.72);
    backdrop-filter: blur(10px);
}

#account-login-screen.is-open {
    display: flex;
}

#account-login-screen .login-box {
    width: min(420px, 100%);
    padding: 34px;
    border-radius: 28px;
    border: 1px solid rgba(255, 42, 133, 0.22);
    background: rgba(15, 15, 20, 0.96);
    transform: translateY(-4vh);
}

#account-login-screen .login-box h1 {
    margin-top: 0;
    margin-bottom: 18px;
    font-size: 2.2rem;
}

#account-login-screen .login-box span {
    color: var(--primary);
}

#account-login-screen .login-back-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 22px;
    color: var(--text-dim);
    text-decoration: none;
    font-weight: 600;
}

#account-login-screen .login-submit {
    width: 100%;
    margin-top: 6px;
}

#account-login-screen .auth-switch {
    margin-top: 14px;
    color: var(--text-dim);
    font-size: 0.9rem;
}

#account-login-screen .auth-switch span {
    color: var(--primary);
    cursor: pointer;
    font-weight: 700;
}

@media (max-width: 980px) {
    .account-grid-top,
    .resource-card {
        grid-template-columns: 1fr;
    }

    .resource-image,
    .resource-image-empty {
        width: 100%;
        height: 220px;
    }

    .details-card {
        grid-template-columns: 1fr;
        padding: 22px;
    }
}

@media (max-width: 640px) {
    #account-login-screen .login-box {
        transform: none;
    }
}
