/* ===== RESET & BASE ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: #1a1a2e;
    background-color: #fafafa;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    text-decoration: none;
    color: inherit;
}


/* ===== NAVBAR ===== */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 40px;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo {
    font-size: 1.4rem;
    font-weight: 700;
    color: #2b2d42;
    display: flex;
    align-items: center;
    gap: 6px;
}

.logo i,
.logo svg {
    color: #ef8354;
    font-size: 1.3rem;
    width: 22px;
    height: 22px;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 24px;
}

.nav-link {
    font-size: 0.95rem;
    color: #555;
    transition: color 0.2s;
}

.nav-link:hover {
    color: #2b2d42;
}

.btn-login {
    padding: 8px 20px;
    border: 1px solid #2b2d42;
    border-radius: 8px;
    color: #2b2d42;
    font-weight: 500;
    transition: background 0.2s, color 0.2s;
}

.btn-login:hover {
    background: #2b2d42;
    color: white;
}

.btn-signup {
    padding: 8px 20px;
    background: linear-gradient(135deg, #ef8354, #e06e3a);
    color: white !important;
    border-radius: 8px;
    font-weight: 500;
    transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
    box-shadow: 0 2px 8px rgba(239, 131, 84, 0.25);
}

.btn-signup:hover {
    background: linear-gradient(135deg, #e06e3a, #c85c2e);
    box-shadow: 0 4px 12px rgba(239, 131, 84, 0.35);
}

.nav-user {
    font-size: 0.9rem;
    font-weight: 600;
    color: #2b2d42;
    padding: 6px 14px;
    background: #f0f4ff;
    border-radius: 20px;
    transition: background 0.2s, color 0.2s;
    cursor: pointer;
    text-decoration: none;
}

.nav-user:hover {
    background: #e0e8ff;
    color: #1a1a2e;
}

.btn-logout {
    padding: 8px 20px;
    border: 1px solid #c0392b;
    border-radius: 6px;
    color: #c0392b !important;
    font-weight: 500;
    font-size: 0.95rem;
    cursor: pointer;
    text-decoration: none;
}

.btn-logout:hover {
    background: #c0392b;
    color: white !important;
}


/* ===== HERO ===== */
.hero {
    padding: 80px 40px 0;
    background: linear-gradient(160deg, #0f1023 0%, #1a1a2e 40%, #232546 70%, #2b2d52 100%);
    color: white;
    position: relative;
    overflow: hidden;
}

/* Subtle grid pattern overlay */
.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.02) 1px, transparent 1px);
    background-size: 48px 48px;
    pointer-events: none;
}

/* Warm glow behind hero text */
.hero::after {
    content: '';
    position: absolute;
    top: 10%;
    left: -5%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(239, 131, 84, 0.12) 0%, transparent 70%);
    pointer-events: none;
}

.hero-grid {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 60px;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-text {
    padding-bottom: 60px;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 16px;
    background: rgba(239, 131, 84, 0.12);
    border: 1px solid rgba(239, 131, 84, 0.25);
    border-radius: 24px;
    font-size: 0.82rem;
    font-weight: 500;
    color: #f4a261;
    margin-bottom: 24px;
    letter-spacing: 0.01em;
}

.hero-badge svg {
    width: 14px;
    height: 14px;
    color: #ef8354;
}

.hero h1 {
    font-size: 3.4rem;
    font-weight: 800;
    margin-bottom: 20px;
    letter-spacing: -1px;
    line-height: 1.12;
}

.hero-accent {
    background: linear-gradient(135deg, #ef8354, #f4a261);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.15rem;
    color: rgba(255, 255, 255, 0.6);
    max-width: 520px;
    margin-bottom: 32px;
    line-height: 1.7;
}

.search-bar {
    display: flex;
    max-width: 560px;
    gap: 0;
    position: relative;
}

.search-icon {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    color: #999;
    pointer-events: none;
    z-index: 2;
}

.search-bar input {
    flex: 1;
    padding: 16px 22px 16px 48px;
    font-size: 1rem;
    border: 2px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px 0 0 12px;
    outline: none;
    background: rgba(255, 255, 255, 0.06);
    backdrop-filter: blur(8px);
    color: white;
    transition: border-color 0.25s, background 0.25s;
}

.search-bar input::placeholder {
    color: rgba(255, 255, 255, 0.35);
}

.search-bar input:focus {
    border-color: rgba(239, 131, 84, 0.5);
    background: rgba(255, 255, 255, 0.09);
}

.search-bar button {
    padding: 16px 32px;
    font-size: 1rem;
    background: linear-gradient(135deg, #ef8354, #e06e3a);
    color: white;
    border: none;
    border-radius: 0 12px 12px 0;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.2s, transform 0.1s;
}

.search-bar button:hover {
    background: linear-gradient(135deg, #e06e3a, #c85c2e);
}

.hero-quick-links {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 16px;
    font-size: 0.82rem;
    flex-wrap: wrap;
}

.hero-quick-links span {
    color: rgba(255, 255, 255, 0.35);
}

.hero-quick-links a {
    color: rgba(255, 255, 255, 0.5);
    padding: 4px 12px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.07);
    transition: color 0.2s, background 0.2s, border-color 0.2s;
}

.hero-quick-links a:hover {
    color: #f4a261;
    background: rgba(239, 131, 84, 0.08);
    border-color: rgba(239, 131, 84, 0.2);
}

/* Hero Activity Card */
.hero-visual {
    padding-bottom: 60px;
}

.hero-activity-card {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 0;
    overflow: hidden;
    backdrop-filter: blur(12px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
}

.activity-header {
    padding: 14px 20px;
    font-size: 0.78rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.6);
    letter-spacing: 0.04em;
    text-transform: uppercase;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    display: flex;
    align-items: center;
    gap: 8px;
}

.activity-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #22c55e;
    display: inline-block;
    animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
    0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.5); }
    50% { opacity: 0.7; box-shadow: 0 0 0 6px rgba(34, 197, 94, 0); }
}

.activity-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 16px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    transition: background 0.2s;
}

.activity-item:last-child {
    border-bottom: none;
}

.activity-item:hover {
    background: rgba(255, 255, 255, 0.03);
}

.activity-faded {
    opacity: 0.45;
}

.activity-avatar {
    font-size: 1.2rem;
    flex-shrink: 0;
    width: 32px;
    text-align: center;
}

.activity-content {
    flex: 1;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.5;
}

.activity-content strong {
    color: rgba(255, 255, 255, 0.95);
    font-weight: 600;
}

.activity-content .user-institution {
    color: rgba(255, 255, 255, 0.45);
    font-size: 0.82rem;
    font-weight: 400;
}

.activity-content em {
    color: #f4a261;
    font-style: normal;
}

.activity-time {
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.3);
    white-space: nowrap;
    padding-top: 2px;
}

/* Trust Bar */
.trust-bar {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 40px;
    padding: 28px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    position: relative;
    z-index: 1;
}

.trust-item {
    text-align: center;
}

.trust-item strong {
    display: block;
    font-size: 1.3rem;
    font-weight: 800;
    color: white;
    letter-spacing: -0.3px;
}

.trust-item span {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.4);
}

.trust-divider {
    width: 1px;
    height: 32px;
    background: rgba(255, 255, 255, 0.1);
}


/* ===== TOPICS ===== */
.topics {
    padding: 60px 40px 70px;
    max-width: 1200px;
    margin: 0 auto;
}

.topics h2 {
    font-size: 1.6rem;
    margin-bottom: 8px;
    color: #2b2d42;
}

.topics > p {
    color: #888;
    font-size: 0.95rem;
    margin-bottom: 28px;
}

.topic-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.topic-card {
    background: white;
    padding: 24px 28px;
    border-radius: 12px;
    border: 1px solid #ebebeb;
    cursor: pointer;
    transition: box-shadow 0.35s, transform 0.35s, border-color 0.35s;
    text-decoration: none;
    color: inherit;
    display: flex;
    align-items: center;
    gap: 16px;
    position: relative;
    overflow: hidden;
}

.topic-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(180deg, #ef8354, #f4a261);
    opacity: 0;
    transition: opacity 0.35s;
}

.topic-card:hover {
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.06);
    transform: translateY(-3px);
    border-color: #ddd;
}

.topic-card:hover::before {
    opacity: 1;
}

.topic-card h3 {
    font-size: 1.05rem;
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.topic-card h3 i,
.topic-card h3 svg {
    color: #ef8354;
    width: 20px;
    height: 20px;
}

.topic-card p {
    font-size: 0.82rem;
    color: #999;
}


/* ===== TRENDING ===== */
.trending {
    padding: 40px 40px 60px;
    max-width: 1200px;
    margin: 0 auto;
}

.trending h2 {
    font-size: 1.6rem;
    margin-bottom: 24px;
    color: #2b2d42;
    display: flex;
    align-items: center;
    gap: 10px;
}

.trending h2 i {
    color: #ef8354;
}

.paper-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.paper-card {
    background: white;
    padding: 24px;
    border-radius: 12px;
    border: 1px solid #e8e8e8;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    cursor: pointer;
    transition: box-shadow 0.3s, transform 0.3s, border-color 0.3s;
}

.paper-card:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    transform: translateY(-3px);
    border-color: #d0d4e0;
}

.paper-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 6px;
    color: #2b2d42;
}

.paper-authors {
    font-size: 0.85rem;
    color: #888;
    margin-bottom: 10px;
}

.paper-tags {
    display: flex;
    gap: 8px;
}

.tag {
    background: #eef0f7;
    color: #2b2d42;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 500;
}

.paper-stats {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 0.82rem;
    color: #777;
    white-space: nowrap;
    text-align: right;
    min-width: 140px;
}

.paper-stats span {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 6px;
}

.paper-stats i {
    font-size: 0.85rem;
    color: #999;
}


/* ===== FOOTER ===== */
.footer {
    background: #1a1a2e;
    color: #999;
    padding: 60px 40px 30px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    max-width: 1100px;
    margin: 0 auto 40px;
}

.footer-col h4 {
    color: #fff;
    font-size: 1rem;
    margin-bottom: 16px;
}

.footer-col p {
    font-size: 0.85rem;
    line-height: 1.7;
    color: #aaa;
}

.footer-col a {
    display: block;
    font-size: 0.85rem;
    color: #aaa;
    margin-bottom: 10px;
    transition: color 0.2s;
}

.footer-col a:hover {
    color: #fff;
}

.footer-bottom {
    text-align: center;
    border-top: 1px solid #3a3d5c;
    padding-top: 24px;
    font-size: 0.85rem;
}


/* ===== FEATURES SECTION ===== */
.features {
    padding: 80px 40px;
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

.features h2 {
    font-size: 2rem;
    color: #2b2d42;
    margin-bottom: 12px;
    letter-spacing: -0.3px;
}

.features-subtitle {
    font-size: 1.05rem;
    color: #777;
    max-width: 580px;
    margin: 0 auto 48px;
    line-height: 1.65;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    text-align: left;
}

.feature-card {
    background: white;
    padding: 32px 28px;
    border-radius: 14px;
    border: 1px solid #ebebeb;
    transition: box-shadow 0.35s, transform 0.35s, border-color 0.35s;
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #ef8354, #f4a261);
    opacity: 0;
    transition: opacity 0.35s;
}

.feature-card:hover {
    box-shadow: 0 12px 36px rgba(0, 0, 0, 0.06);
    transform: translateY(-5px);
    border-color: #ddd;
}

.feature-card:hover::before {
    opacity: 1;
}

.feature-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: linear-gradient(135deg, #fff0ea 0%, #fde8dd 100%);
    margin-bottom: 18px;
}

.feature-icon i,
.feature-icon svg {
    font-size: 1.3rem;
    color: #ef8354;
    width: 24px;
    height: 24px;
}

.feature-card h3 {
    font-size: 1.1rem;
    color: #2b2d42;
    margin-bottom: 10px;
    font-weight: 700;
}

.feature-card p {
    font-size: 0.88rem;
    color: #666;
    line-height: 1.7;
}


/* ===== UPLOAD CTA ===== */
.upload-cta {
    background: linear-gradient(135deg, #f4f6fb 0%, #eaecf4 50%, #e4e8f2 100%);
    padding: 80px 40px;
}

.upload-cta-content {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 60px;
}

.upload-cta-text {
    flex: 1;
}

.upload-cta-text h2 {
    font-size: 2rem;
    color: #2b2d42;
    margin-bottom: 16px;
}

.upload-cta-text p {
    font-size: 1.1rem;
    color: #555;
    margin-bottom: 24px;
}

.btn-upload {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 32px;
    font-size: 1.1rem;
    background: linear-gradient(135deg, #ef8354, #e06e3a);
    color: white;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
    box-shadow: 0 4px 12px rgba(239, 131, 84, 0.3);
}

.btn-upload:hover {
    background: linear-gradient(135deg, #e06e3a, #c85c2e);
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(239, 131, 84, 0.4);
}

.upload-note {
    font-size: 0.82rem !important;
    color: #999 !important;
    margin-top: 12px !important;
}

.upload-cta-visual {
    flex: 1;
    display: flex;
    justify-content: center;
}

.upload-dropzone {
    width: 320px;
    height: 220px;
    border: 3px dashed #c0c8e0;
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: white;
    transition: border-color 0.3s, background 0.3s, transform 0.3s;
    cursor: pointer;
}

.upload-dropzone:hover {
    border-color: #ef8354;
    background: #fff8f5;
    transform: translateY(-2px);
}

.dropzone-icon {
    font-size: 2.5rem;
    color: #c0c8e0;
    transition: color 0.3s;
}

.upload-dropzone:hover .dropzone-icon {
    color: #ef8354;
}

.upload-dropzone p {
    font-size: 1rem;
    color: #555;
    font-weight: 500;
}

.upload-dropzone span {
    font-size: 0.82rem;
    color: #aaa;
}


/* ===== DISCUSSION PREVIEW ===== */
.discussion-preview {
    padding: 80px 40px;
    max-width: 900px;
    margin: 0 auto;
}

.discussion-preview h2 {
    font-size: 1.6rem;
    color: #2b2d42;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.discussion-preview h2 i {
    color: #ef8354;
}

.discussion-subtitle {
    color: #888;
    font-size: 1rem;
    margin-bottom: 32px;
}

.discussion-thread {
    background: white;
    border-radius: 14px;
    border: 1px solid #e0e0e0;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
}

.thread-header {
    padding: 16px 24px;
    background: #f8f9fc;
    border-bottom: 1px solid #e8e8e8;
}

.thread-paper {
    font-size: 0.9rem;
    font-weight: 600;
    color: #2b2d42;
}

.comment {
    display: flex;
    gap: 14px;
    padding: 20px 24px;
    border-bottom: 1px solid #f0f0f0;
}

.comment:last-child {
    border-bottom: none;
}

.comment-reply {
    padding-left: 58px;
    background: #fafbfe;
}

.comment-avatar {
    font-size: 1.6rem;
    flex-shrink: 0;
    width: 40px;
    text-align: center;
}

.comment-body {
    flex: 1;
}

.comment-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
    flex-wrap: wrap;
}

.comment-meta strong {
    font-size: 0.9rem;
    color: #2b2d42;
}

.comment-meta .user-institution {
    font-size: 0.82rem;
    color: #999;
    font-weight: 400;
}

.comment-role {
    font-size: 0.78rem;
    color: #888;
    background: #f0f2f8;
    padding: 2px 8px;
    border-radius: 4px;
}

.comment-time {
    font-size: 0.78rem;
    color: #aaa;
}

.comment-body > p {
    font-size: 0.9rem;
    color: #444;
    line-height: 1.6;
    margin-bottom: 10px;
}

.comment-actions {
    display: flex;
    gap: 16px;
    font-size: 0.8rem;
    color: #999;
}


/* ===== FINAL CTA ===== */
.final-cta {
    text-align: center;
    padding: 100px 40px;
    background: linear-gradient(160deg, #0f1023 0%, #1a1a2e 40%, #232546 70%, #2b2d52 100%);
    color: white;
    position: relative;
    overflow: hidden;
}

.final-cta::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.015) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.015) 1px, transparent 1px);
    background-size: 48px 48px;
    pointer-events: none;
}

.final-cta::after {
    content: '';
    position: absolute;
    bottom: -20%;
    right: -5%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(239, 131, 84, 0.1) 0%, transparent 70%);
    pointer-events: none;
}

.final-cta h2 {
    font-size: 2.2rem;
    margin-bottom: 16px;
    letter-spacing: -0.5px;
    position: relative;
    z-index: 1;
}

.final-cta p {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.55);
    max-width: 550px;
    margin: 0 auto 32px;
    position: relative;
    z-index: 1;
}

.final-cta-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
    position: relative;
    z-index: 1;
}

.btn-get-started {
    padding: 14px 36px;
    background: linear-gradient(135deg, #ef8354, #e06e3a);
    color: white;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: 600;
    transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
    box-shadow: 0 4px 16px rgba(239, 131, 84, 0.35);
}

.btn-get-started:hover {
    background: linear-gradient(135deg, #e06e3a, #c85c2e);
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(239, 131, 84, 0.45);
}

.btn-see-demo {
    padding: 14px 36px;
    border: 2px solid rgba(255,255,255,0.25);
    color: white;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: 500;
    transition: border-color 0.3s, background 0.3s, transform 0.15s;
}

.btn-see-demo:hover {
    border-color: rgba(255,255,255,0.6);
    background: rgba(255,255,255,0.08);
    transform: translateY(-1px);
}


/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
    .hero-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .hero-visual {
        display: none;
    }

    .hero-text {
        text-align: center;
        padding-bottom: 40px;
    }

    .hero-subtitle {
        margin-left: auto;
        margin-right: auto;
    }

    .search-bar {
        margin: 0 auto;
    }

    .hero-quick-links {
        justify-content: center;
    }

    .trust-bar {
        gap: 24px;
        flex-wrap: wrap;
    }
}

@media (max-width: 768px) {
    .topic-grid {
        grid-template-columns: 1fr;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .paper-card {
        flex-direction: column;
    }

    .paper-stats {
        flex-direction: row;
        gap: 16px;
        margin-top: 12px;
        text-align: left;
    }

    .hero h1 {
        font-size: 2.2rem;
    }

    .navbar {
        padding: 12px 20px;
    }

    .nav-right {
        gap: 12px;
    }

    .upload-cta-content {
        flex-direction: column;
        text-align: center;
    }

    .features h2,
    .upload-cta-text h2,
    .final-cta h2 {
        font-size: 1.6rem;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .comment-reply {
        padding-left: 24px;
    }

    .trust-bar {
        gap: 16px;
    }

    .trust-divider {
        display: none;
    }

    .trust-item strong {
        font-size: 1.1rem;
    }
}

/* ===== ENTRANCE ANIMATIONS ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-badge {
    animation: fadeInUp 0.6s ease-out;
}

.hero h1 {
    animation: fadeInUp 0.6s ease-out 0.1s both;
}

.hero-subtitle {
    animation: fadeInUp 0.6s ease-out 0.2s both;
}

.hero .search-bar {
    animation: fadeInUp 0.6s ease-out 0.3s both;
}

.hero-quick-links {
    animation: fadeInUp 0.6s ease-out 0.4s both;
}

.hero-activity-card {
    animation: fadeInUp 0.7s ease-out 0.35s both;
}


/* ===== LEGAL PAGES (Terms, DMCA) ===== */
.legal-page {
    padding: 60px 40px 80px;
    max-width: 820px;
    margin: 0 auto;
}

.legal-container h1 {
    font-size: 2.2rem;
    color: #2b2d42;
    margin-bottom: 4px;
}

.legal-updated {
    font-size: 0.85rem;
    color: #999;
    margin-bottom: 40px;
}

.legal-section {
    margin-bottom: 36px;
}

.legal-section h2 {
    font-size: 1.2rem;
    color: #2b2d42;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid #eee;
}

.legal-section p {
    font-size: 0.95rem;
    color: #555;
    line-height: 1.75;
    margin-bottom: 12px;
}

.legal-section ul,
.legal-section ol {
    padding-left: 24px;
    margin-bottom: 16px;
}

.legal-section li {
    font-size: 0.93rem;
    color: #555;
    line-height: 1.7;
    margin-bottom: 6px;
}

.legal-section a {
    color: #ef8354;
    text-decoration: none;
    font-weight: 500;
}

.legal-section a:hover {
    text-decoration: underline;
}

/* DMCA step process */
.dmca-steps {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-top: 16px;
}

.dmca-step {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    padding: 20px;
    background: #f8f9fc;
    border-radius: 12px;
    border: 1px solid #e8ecf4;
}

.dmca-step-number {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #2b2d42;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
}

.dmca-step-content h3 {
    font-size: 1rem;
    color: #2b2d42;
    margin-bottom: 4px;
}

.dmca-step-content p {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 0;
}

.dmca-contact-box {
    padding: 24px;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 12px;
}

.dmca-contact-box p {
    margin-bottom: 6px;
}

.dmca-contact-box a {
    color: #16a34a;
}

/* Rights confirmation checkbox */
.rights-checkbox {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 0.82rem;
    color: #777;
    margin: 12px 0;
    max-width: 380px;
    text-align: left;
    cursor: pointer;
    line-height: 1.5;
}

/* Center the checkbox inside centered containers (viewer dropzone) */
.viewer-dropzone .rights-checkbox,
.no-pdf-dropzone .rights-checkbox {
    margin: 12px auto;
}

.rights-checkbox input[type="checkbox"] {
    margin-top: 3px;
    flex-shrink: 0;
    accent-color: #ef8354;
    width: 16px;
    height: 16px;
    cursor: pointer;
}

.rights-checkbox a {
    color: #ef8354;
    text-decoration: none;
    font-weight: 500;
}

.rights-checkbox a:hover {
    text-decoration: underline;
}

@media (max-width: 768px) {
    .legal-page {
        padding: 40px 20px 60px;
    }

    .legal-container h1 {
        font-size: 1.6rem;
    }

    .dmca-step {
        flex-direction: column;
        gap: 10px;
    }
}


/* ===== UPLOAD CONFIRMATION DIALOG ===== */
.confirm-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    padding: 20px;
}

.confirm-dialog {
    background: white;
    border-radius: 16px;
    padding: 32px;
    max-width: 520px;
    width: 100%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
    animation: fadeInUp 0.25s ease-out;
}

.confirm-dialog h3 {
    font-size: 1.3rem;
    color: #2b2d42;
    margin-bottom: 12px;
}

.confirm-match-status {
    display: inline-block;
    font-size: 0.82rem;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 20px;
    margin-bottom: 20px;
}

.match-found {
    background: #f0fdf4;
    color: #16a34a;
    border: 1px solid #bbf7d0;
}

.match-unknown {
    background: #fefce8;
    color: #a16207;
    border: 1px solid #fde68a;
}

.confirm-field {
    display: block;
    margin-bottom: 16px;
}

.confirm-field span {
    display: block;
    font-size: 0.82rem;
    font-weight: 600;
    color: #666;
    margin-bottom: 4px;
}

.confirm-field input {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 0.95rem;
    font-family: 'Inter', sans-serif;
    color: #2b2d42;
    transition: border-color 0.2s;
    box-sizing: border-box;
}

.confirm-field input:focus {
    outline: none;
    border-color: #ef8354;
    box-shadow: 0 0 0 3px rgba(239, 131, 84, 0.1);
}

.confirm-abstract {
    margin-bottom: 20px;
}

.confirm-abstract span {
    display: block;
    font-size: 0.82rem;
    font-weight: 600;
    color: #666;
    margin-bottom: 4px;
}

.confirm-abstract p {
    font-size: 0.85rem;
    color: #888;
    line-height: 1.55;
    background: #f8f9fc;
    padding: 12px;
    border-radius: 8px;
    border: 1px solid #eee;
    margin: 0;
}

.confirm-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 8px;
}

.confirm-btn-cancel {
    padding: 10px 20px;
    border: 1px solid #ddd;
    border-radius: 8px;
    background: white;
    color: #666;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
}

.confirm-btn-cancel:hover {
    background: #f5f5f5;
}

.confirm-btn-ok {
    padding: 10px 24px;
    border: none;
    border-radius: 8px;
    background: linear-gradient(135deg, #ef8354, #e06e3a);
    color: white;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
    box-shadow: 0 2px 8px rgba(239, 131, 84, 0.3);
}

.confirm-btn-ok:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(239, 131, 84, 0.4);
}

@media (max-width: 480px) {
    .confirm-dialog {
        padding: 24px;
    }
    .confirm-actions {
        flex-direction: column-reverse;
    }
    .confirm-btn-ok,
    .confirm-btn-cancel {
        width: 100%;
        text-align: center;
    }
}
