/* Scoped styles for Single Submission Page */
:root {
    --loft-teal: #1D9E75;
    --loft-bg: #f9f9f9;
    --loft-border: #e0e0e0;
    --loft-text: #333333;
    --loft-meta: #777777;
    --loft-accent: #e06649;
}

.loft-container {
    max-width: 800px;
    margin: 0 auto;
    font-family: 'DM Sans', sans-serif;
    color: var(--loft-text);
    line-height: 1.6;
    padding: 40px 20px;
}

.loft-container * {
    box-sizing: border-box;
}

/* Labels */
.loft-section-label {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--loft-meta);
    margin-bottom: 8px;
    font-weight: 700;
}

/* Single Header */
.loft-single-header {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--loft-accent);
    font-weight: 700;
    margin-bottom: 25px;
    border-bottom: 1px solid var(--loft-border);
    padding-bottom: 15px;
}

/* 1. Diagnosis */
.loft-diagnosis-block {
    margin-bottom: 50px;
    padding-right: 20px;
}
.loft-diagnosis {
    font-family: 'Playfair Display', serif;
    font-size: 1.3rem;
    line-height: 1.8;
    color: var(--loft-text);
    font-style: italic;
    border-left: 4px solid var(--loft-accent);
    padding-left: 25px;
    margin-top: 15px;
}

/* Cards */
.loft-card {
    background: var(--loft-bg);
    border: 1px solid var(--loft-border);
    border-radius: 8px;
    padding: 24px;
    margin-bottom: 30px;
}

/* 2. If This Is You */
.loft-if-this-is-you-block {
    border-left: 4px solid var(--loft-teal);
    border-radius: 0 8px 8px 0;
}

/* 3. Audio Player */
.loft-audio-container {
    background: var(--loft-bg);
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 30px;
    text-align: center;
}
.loft-audio-loading {
    font-size: 0.9rem;
    color: var(--loft-meta);
    margin-bottom: 10px;
}
.loft-audio-player {
    width: 100%;
    outline: none;
    display: none; /* Hidden until loaded */
}
.loft-audio-error {
    color: #c00;
    font-weight: bold;
    display: none;
}

.loft-submitted-video-block .loft-submitted-video-wrap {
    margin: 0;
    word-break: break-word;
}
.loft-submitted-video-link {
    color: var(--loft-teal);
    font-weight: 600;
    text-decoration: underline;
}

.loft-video-sample-start {
    margin: 12px 0 0;
    font-size: 15px;
    line-height: 1.5;
    color: var(--loft-text, #333);
}
.loft-video-sample-start-label {
    font-weight: 600;
    margin-right: 0.35em;
}
.loft-video-sample-start-time {
    font-variant-numeric: tabular-nums;
}

/* 4. Timestamped Critique */
.loft-timestamp-row {
    display: flex;
    padding: 12px 15px;
    margin: 0 -15px;
    border-bottom: 1px solid var(--loft-border);
    cursor: pointer;
    transition: all 0.3s ease;
    border-left: 3px solid transparent;
}
.loft-timestamp-row:last-child {
    border-bottom: none;
}
.loft-timestamp-row:hover {
    color: var(--loft-teal);
    background: #fdfdfd;
    border-left: 3px solid var(--loft-accent);
    transform: translateX(4px);
}
.loft-timestamp-time {
    font-weight: 700;
    min-width: 60px;
    color: var(--loft-teal);
    pointer-events: none; /* Let the row grab the click */
    font-family: monospace;
    font-size: 1.1rem;
}
.loft-timestamp-note {
    pointer-events: none;
    font-size: 1.05rem;
    line-height: 1.5;
}

/* 5. Resources (lessons, posts, exercises, videos) */
.loft-resources-container {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}
.loft-resource-item {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}
.loft-next-step-box {
    margin-top: 15px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 20px;
}
.loft-next-step-desc {
    flex: 1;
    min-width: 250px;
    margin: 0;
    font-size: 1.05rem;
    color: var(--loft-text);
}
.loft-next-step-button {
    display: inline-block;
    background: var(--loft-teal);
    color: #ffffff !important;
    padding: 12px 24px;
    text-decoration: none !important;
    border-radius: 4px;
    font-weight: 700;
    transition: all 0.3s ease;
    white-space: nowrap;
    border: none;
    box-shadow: 0 4px 10px rgba(29, 158, 117, 0.2);
}
.loft-resource-button {
    width: 100%;
    box-sizing: border-box;
    text-align: center;
    white-space: normal;
}
.loft-next-step-button:hover {
    background: var(--loft-accent);
    color: #ffffff !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(224, 102, 73, 0.3);
}

/* 6. Your Next 3 Steps */
.loft-next-steps-list {
    margin: 15px 0 0 0;
    padding: 0;
    list-style-type: none;
    counter-reset: loft-step-counter;
}
.loft-next-steps-list li {
    position: relative;
    margin-bottom: 16px;
    padding-left: 45px;
    font-size: 1.1rem;
    line-height: 1.5;
}
.loft-next-steps-list li::before {
    counter-increment: loft-step-counter;
    content: counter(loft-step-counter);
    position: absolute;
    left: 0;
    top: -2px;
    color: var(--loft-accent);
    font-family: 'Playfair Display', serif;
    font-size: 1.8rem;
    font-weight: 700;
    line-height: 1;
}

/* 7. Community Responses */
.loft-comments-section {
    margin-top: 60px;
    padding-top: 40px;
    border-top: 2px solid var(--loft-border);
}
.loft-comments-header {
    font-size: 1.8rem;
    margin-bottom: 10px;
}
.loft-comments-subheader {
    color: var(--loft-meta);
    margin-bottom: 30px;
    font-size: 1.1rem;
}

.loft-comment {
    padding: 20px 0;
    border-bottom: 1px solid var(--loft-border);
}
.loft-comment-meta {
    font-size: 0.9rem;
    color: var(--loft-meta);
    margin-bottom: 8px;
}
.loft-comment-meta strong {
    color: var(--loft-text);
}
.loft-comment.flagged {
    background: rgba(29, 158, 117, 0.08);
    padding: 20px;
    border-radius: 8px;
    border-bottom: none;
    margin: 15px 0;
}
.loft-comment-body p {
    margin: 0 0 10px 0;
}
.loft-comment-body p:last-child {
    margin-bottom: 0;
}

/* Comment Form & Prompts */
.loft-auth-prompt {
    background: var(--loft-bg);
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    margin-bottom: 30px;
    margin-top: 40px;
}

/* 8. Series Navigation */
.loft-series-nav {
    display: flex;
    justify-content: space-between;
    margin-top: 50px;
    padding-top: 20px;
    border-top: 1px solid var(--loft-border);
}
.loft-series-nav a {
    color: var(--loft-teal);
    text-decoration: none;
    font-weight: 700;
}
.loft-series-nav a:hover {
    text-decoration: underline;
}

/* 9. Archive Template Grid */
.loft-archive-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 60px 20px;
    font-family: 'DM Sans', sans-serif;
}
.loft-archive-header {
    text-align: center;
    margin-bottom: 50px;
}
.loft-archive-title {
    font-family: 'Playfair Display', serif;
    font-size: 3rem;
    color: #111;
    margin-bottom: 10px;
}
.loft-archive-description {
    font-size: 1.2rem;
    color: var(--loft-meta);
}
.loft-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 30px;
    margin-bottom: 60px;
}
.loft-grid-card {
    background: #fff;
    border: 1px solid var(--loft-border);
    border-radius: 12px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    overflow: hidden;
}
.loft-grid-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.06);
}
.loft-card-link {
    display: block;
    text-decoration: none;
    color: inherit;
    padding: 30px;
    height: 100%;
}
.loft-card-link:hover {
    text-decoration: none;
    color: inherit;
}
.loft-card-meta {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 15px;
}
.loft-card-instrument {
    color: var(--loft-teal);
    font-weight: 700;
}
.loft-card-date {
    color: var(--loft-meta);
}
.loft-card-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.6rem;
    line-height: 1.3;
    margin: 0 0 10px 0;
    color: #111;
}
.loft-card-author {
    font-size: 1rem;
    color: var(--loft-text);
    margin-bottom: 25px;
}
.loft-card-footer {
    border-top: 1px solid var(--loft-border);
    padding-top: 20px;
}
.loft-badge {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.loft-badge-critiqued {
    background: rgba(29, 158, 117, 0.1);
    color: var(--loft-teal);
}
.loft-badge-pending {
    background: #f1f1f1;
    color: #666;
}
.loft-pagination {
    text-align: center;
}
.loft-pagination .page-numbers {
    display: inline-block;
    padding: 10px 16px;
    margin: 0 5px;
    background: #fff;
    border: 1px solid var(--loft-border);
    border-radius: 4px;
    color: var(--loft-text);
    font-weight: 700;
    text-decoration: none;
}
.loft-pagination .page-numbers.current,
.loft-pagination .page-numbers:hover {
    background: var(--loft-teal);
    color: #fff;
    border-color: var(--loft-teal);
}
