/* Min Profil – dark card layout matching reference design */

.profil-main {
    padding: calc(72px + 3rem) 0 4rem;
    min-height: 100vh;
    background: var(--black);
}

.profil-require-login {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--gray-light);
}

.profil-require-login p {
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}

.profil-content {
    max-width: 720px;
    margin: 0 auto;
}

.profil-page-title {
    font-size: clamp(1.75rem, 4vw, 2.25rem);
    font-weight: 700;
    color: var(--white);
    margin-bottom: 0.35rem;
    letter-spacing: -0.02em;
}

.profil-page-intro {
    color: var(--gray-light);
    font-size: 1rem;
    margin-bottom: 2.5rem;
}

/* Cards – Matrix charcoal, rounded */
.profil-card {
    background: var(--charcoal);
    border: 1px solid var(--gray-dark);
    border-radius: var(--radius-lg);
    padding: 1.5rem 1.75rem;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow);
}

.profil-card-title {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--white);
    margin-bottom: 1.25rem;
    border-bottom: 1px solid rgba(0, 255, 102, 0.2);
    padding-bottom: 0.6rem;
}

.profil-card-icon {
    color: var(--matrix-green);
    font-size: 1rem;
    opacity: 0.95;
}

.profil-card-subtitle {
    font-size: 0.9rem;
    color: var(--gray-light);
    margin-bottom: 1rem;
}

/* Brugerinformation block */
.profil-user-block {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.25rem;
}

.profil-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.profil-user-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.profil-username {
    font-weight: 600;
    font-size: 1.15rem;
    color: var(--white);
}

.profil-discord-id {
    font-size: 0.85rem;
    color: var(--gray-light);
    font-family: ui-monospace, monospace;
}

/* Meta row: Medlem siden, Total spilletid */
.profil-meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem 2rem;
}

.profil-meta-item {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.95rem;
    color: var(--gray-light);
}

.profil-meta-icon {
    color: var(--matrix-green);
    opacity: 0.9;
    font-size: 0.9rem;
}

.profil-meta-item strong {
    color: var(--white);
    font-weight: 600;
}

/* Discord roles */
.profil-roles-wrap {
    margin-top: 1.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid rgba(0, 255, 102, 0.15);
}

.profil-roles-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--white);
    margin-bottom: 0.75rem;
}

.profil-roles-title .profil-card-icon {
    font-size: 0.9rem;
}

.profil-roles-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.profil-role-pill {
    display: inline-block;
    padding: 0.35rem 0.75rem;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--gray-light);
    background: rgba(0, 255, 102, 0.1);
    border: 1px solid rgba(0, 255, 102, 0.25);
    border-radius: 999px;
}

.profil-roles-empty {
    font-size: 0.9rem;
    color: var(--gray-light);
    margin: 0;
}

/* Applications list */
.profil-applications-loading {
    color: var(--gray-light);
    font-size: 0.95rem;
    padding: 0.5rem 0;
}

.profil-applications-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.profil-application-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.75rem;
    padding: 1rem 1.1rem;
    background: rgba(0, 255, 102, 0.04);
    border: 1px solid var(--gray-dark);
    border-radius: var(--radius);
    transition: border-color var(--transition), background var(--transition);
}

.profil-application-item:hover {
    background: rgba(0, 255, 102, 0.08);
    border-color: rgba(0, 255, 102, 0.3);
}

.profil-application-left {
    flex: 1;
    min-width: 0;
}

.profil-application-name {
    font-weight: 600;
    font-size: 1rem;
    color: var(--white);
    display: block;
    margin-bottom: 0.2rem;
}

.profil-application-date {
    font-size: 0.85rem;
    color: var(--gray-light);
}

.profil-application-approved-msg {
    display: block;
    font-size: 0.9rem;
    color: var(--matrix-green);
    font-weight: 500;
    margin-top: 0.25rem;
}

.profil-application-right {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-shrink: 0;
}

/* Status pill – Matrix green palette */
.profil-status-pill {
    display: inline-flex;
    align-items: center;
    padding: 0.35rem 0.75rem;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 500;
}

.profil-status-pill--pending {
    background: rgba(0, 255, 102, 0.25);
    color: var(--neon-green);
    border: 1px solid rgba(0, 255, 102, 0.4);
}

.profil-status-pill--accepted {
    background: var(--matrix-green);
    color: var(--black);
}

.profil-status-pill--rejected {
    background: rgba(239, 68, 68, 0.25);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.4);
}

.profil-status-pill--invited_to_interview {
    background: rgba(43, 255, 136, 0.2);
    color: var(--neon-green);
    border: 1px solid rgba(43, 255, 136, 0.4);
}

/* Rediger button – Matrix outline */
.profil-btn-edit {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--gray-light);
    background: transparent;
    border: 1px solid var(--gray-dark);
    border-radius: var(--radius);
    font-family: var(--font);
    cursor: pointer;
    text-decoration: none;
    transition: border-color var(--transition), background var(--transition), color var(--transition);
}

.profil-btn-edit:hover {
    border-color: var(--matrix-green);
    background: rgba(0, 255, 102, 0.08);
    color: var(--matrix-green);
}

.profil-btn-edit i {
    font-size: 0.8rem;
    opacity: 0.9;
}

.profil-application-btn-group {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.profil-btn-ansog-igen {
    color: var(--matrix-green) !important;
    border-color: var(--matrix-green) !important;
    text-decoration: none;
}

.profil-btn-ansog-igen:hover {
    background: var(--matrix-green) !important;
    color: var(--black) !important;
}

/* Empty state */
.profil-applications-empty {
    text-align: center;
    padding: 2rem 1rem;
    color: var(--gray-light);
}

.profil-applications-empty p {
    margin-bottom: 1rem;
    font-size: 1rem;
}

/* Submission detail modal (profil) */
.profil-submission-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 1rem;
}
.profil-submission-modal.hidden {
    display: none;
}
.profil-submission-modal-box {
    background: var(--gray-dark);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}
.profil-submission-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.profil-submission-modal-header h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--white);
    margin: 0;
}
.profil-submission-modal-close {
    background: none;
    border: none;
    color: var(--gray-light);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.25rem;
}
.profil-submission-modal-close:hover {
    color: var(--white);
}
.profil-submission-modal-body {
    padding: 1.5rem;
}
.profil-submission-status {
    display: inline-block;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    color: var(--white);
    font-weight: 600;
    margin-bottom: 1rem;
}
.profil-submission-meta {
    color: var(--gray-light);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}
.profil-submission-responses {
    margin-top: 1rem;
}
.profil-submission-response {
    padding: 1rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 4px;
    margin-bottom: 0.75rem;
}
.profil-submission-response strong {
    color: var(--white);
    display: block;
    margin-bottom: 0.5rem;
}
.profil-submission-response span {
    color: var(--gray-light);
    white-space: pre-wrap;
}
.profil-submission-comments {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}
.profil-submission-comments h4 {
    font-size: 1rem;
    color: var(--white);
    margin-bottom: 0.75rem;
}
.profil-submission-comment {
    padding: 0.75rem;
    background: rgba(0, 255, 136, 0.06);
    border-left: 3px solid var(--matrix-green);
    border-radius: 0 4px 4px 0;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    color: var(--gray-light);
}

/* ── Twitch-tilknytning ────────────────────────────────────── */

.profil-card-twitch .profil-card-icon {
    color: #9146FF;
}

.profil-twitch-form {
    margin-top: 0.5rem;
}

.profil-twitch-input-row {
    display: flex;
    align-items: center;
    gap: 0;
    margin-bottom: 1rem;
    background: var(--black);
    border: 1px solid var(--gray-dark);
    border-radius: var(--radius);
    overflow: hidden;
    transition: border-color var(--transition);
}

.profil-twitch-input-row:focus-within {
    border-color: #9146FF;
}

.profil-twitch-prefix {
    padding: 0.65rem 0.75rem;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--gray-light);
    background: rgba(145, 70, 255, 0.1);
    white-space: nowrap;
    user-select: none;
}

.profil-twitch-input {
    flex: 1;
    padding: 0.65rem 0.75rem;
    font-size: 0.95rem;
    font-family: var(--font);
    color: var(--white);
    background: transparent;
    border: none;
    outline: none;
    min-width: 0;
}

.profil-twitch-input::placeholder {
    color: rgba(191, 187, 255, 0.4);
}

.profil-twitch-btn {
    background: #9146FF;
    border-color: #9146FF;
    color: var(--white);
}

.profil-twitch-btn:hover {
    background: #7c3aed;
    border-color: #7c3aed;
    box-shadow: 0 6px 24px rgba(145, 70, 255, 0.4);
}

.profil-twitch-error {
    margin-top: 0.75rem;
    font-size: 0.9rem;
    color: #f87171;
}

.profil-twitch-linked {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
    padding: 1rem 1.1rem;
    background: rgba(145, 70, 255, 0.08);
    border: 1px solid rgba(145, 70, 255, 0.25);
    border-radius: var(--radius);
}

.profil-twitch-linked-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.profil-twitch-linked-icon {
    font-size: 1.5rem;
    color: #9146FF;
}

.profil-twitch-linked-label {
    display: block;
    font-size: 0.8rem;
    color: var(--gray-light);
    margin-bottom: 0.1rem;
}

.profil-twitch-linked-name {
    display: block;
    font-weight: 600;
    font-size: 1rem;
    color: #9146FF;
    text-decoration: none;
    transition: color var(--transition);
}

.profil-twitch-linked-name:hover {
    color: #7c3aed;
}

.profil-twitch-unlink-btn {
    font-size: 0.85rem;
    padding: 0.5rem 1rem;
    border-color: rgba(248, 113, 113, 0.4);
    color: #f87171;
}

.profil-twitch-unlink-btn:hover {
    border-color: #f87171;
    background: rgba(248, 113, 113, 0.1);
    color: #f87171;
}

.profil-twitch-no-role {
    font-size: 0.95rem;
    color: var(--gray-light);
}

.profil-twitch-no-role strong {
    color: #9146FF;
}

@media (max-width: 640px) {
    .profil-application-item {
        flex-direction: column;
        align-items: flex-start;
    }
    .profil-application-right {
        width: 100%;
        justify-content: flex-start;
    }
}
