/* ================================================================
   AUTHOR PROFILE PAGE STYLING (PRODUCTION-GRADE E-E-A-T)
   Namespace: aft-author-*, aft-social-*
   ================================================================ */

.aft-author-wrap {
    max-width: 1360px;
    margin: 0 auto 60px;
    padding: calc(var(--header-h) + 24px) 20px 0;
    width: 100%;
}

@media (min-width: 640px) {
    .aft-author-wrap {
        padding: calc(var(--header-h) + 32px) 24px 0;
        margin: 0 auto 80px;
    }
}

@media (min-width: 1024px) {
    .aft-author-wrap {
        padding: calc(var(--header-h) + 36px) 40px 0;
    }
}

/* Breadcrumbs */
.aft-author-breadcrumb {
    display: inline-flex !important;
    justify-content: flex-start !important;
    align-items: center !important;
    gap: 8px !important;
    font-size: 0.88rem !important;
    color: var(--text-muted);
    margin-bottom: 22px !important;
    padding: 0 !important;
    height: auto !important;
    max-width: 100% !important;
    width: auto !important;
    line-height: 1.4 !important;
}

.aft-author-breadcrumb a {
    color: var(--text-muted);
    text-decoration: none;
    transition: color 0.18s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-weight: 500;
}

.aft-author-breadcrumb a:hover {
    color: var(--accent);
}

.aft-author-breadcrumb a i.fa-home {
    color: #6366f1;
    font-size: 0.95rem;
}

html.dark-theme .aft-author-breadcrumb a i.fa-home {
    color: #818cf8;
}

.aft-author-breadcrumb i.fa-chevron-right {
    font-size: 0.62rem;
    color: var(--text-muted);
    opacity: 0.55;
    margin: 0 2px;
}

.aft-author-breadcrumb-current {
    color: var(--text);
    font-weight: 600;
    text-transform: capitalize;
}

/* ================================================================
   HERO PROFILE CARD (Matches Mockup Spec 1:1)
   ================================================================ */

.aft-author-hero {
    background: var(--bg-card);
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: 22px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.04), 0 20px 40px -15px rgba(0, 0, 0, 0.07);
    margin-bottom: 28px;
    position: relative;
    overflow: hidden;
    transition: background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

/* Dark mode card elevation & glow */
html.dark-theme .aft-author-hero {
    background: #0b1120;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 10px 35px rgba(0, 0, 0, 0.45);
}

/* Top Cover Banner Strip (Indigo -> Violet -> Blue Wave) */
.aft-author-cover-strip {
    height: 105px;
    width: 100%;
    background: radial-gradient(circle at 85% 15%, rgba(255, 255, 255, 0.28) 0%, transparent 45%),
                radial-gradient(circle at 20% 80%, rgba(255, 255, 255, 0.15) 0%, transparent 35%),
                linear-gradient(135deg, #6366f1 0%, #8b5cf6 45%, #3b82f6 100%);
    position: relative;
}

/* Inner card body below cover strip */
.aft-author-card-content {
    padding: 0 36px 32px;
}

@media (max-width: 768px) {
    .aft-author-card-content {
        padding: 0 20px 24px;
    }
}

/* Main Top Row: Avatar + Bio Column + Meta Column */
.aft-author-main-row {
    display: flex;
    gap: 28px;
    align-items: flex-start;
    margin-bottom: 28px;
}

@media (max-width: 900px) {
    .aft-author-main-row {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 16px;
    }
}

/* Overlapping Avatar with Glowing Ring */
.aft-author-avatar-col {
    margin-top: -55px;
    flex-shrink: 0;
    position: relative;
    z-index: 5;
}

.aft-author-avatar-glow-ring {
    padding: 4px;
    border-radius: 50%;
    background: linear-gradient(135deg, #38bdf8 0%, #818cf8 50%, #c084fc 100%);
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.35);
    display: inline-block;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

html.dark-theme .aft-author-avatar-glow-ring {
    box-shadow: 0 0 25px rgba(56, 189, 248, 0.45), 0 0 50px rgba(99, 102, 241, 0.3);
}

.aft-author-avatar-glow-ring:hover {
    transform: scale(1.03);
}

.aft-author-avatar {
    width: 126px;
    height: 126px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid #ffffff;
    display: block;
    background: #ffffff;
}

html.dark-theme .aft-author-avatar {
    border-color: #0b1120;
    background: #0b1120;
}

.aft-author-avatar-placeholder {
    width: 126px;
    height: 126px;
    border-radius: 50%;
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3.2rem;
    font-weight: 800;
    border: 4px solid #ffffff;
}

html.dark-theme .aft-author-avatar-placeholder {
    border-color: #0b1120;
}

/* Bio Column */
.aft-author-bio-col {
    flex: 1;
    min-width: 0;
    padding-top: 14px;
}

.aft-author-name-row {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

@media (max-width: 900px) {
    .aft-author-name-row {
        justify-content: center;
    }
}

.aft-author-name {
    font-size: clamp(1.75rem, 3.2vw, 2.2rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    text-transform: capitalize;
    color: var(--text);
    margin: 0;
    line-height: 1.15;
}

.aft-author-verified-icon {
    color: #3b82f6;
    font-size: 1.35rem;
    display: inline-flex;
    align-items: center;
    cursor: default;
}

.aft-author-role-pill {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    color: #ffffff;
    border-radius: 9999px;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    padding: 4px 12px;
    letter-spacing: 0.05em;
    box-shadow: 0 2px 6px rgba(99, 102, 241, 0.25);
    white-space: nowrap;
}

/* Tagline & Rich Bio */
.aft-author-tagline {
    font-size: 1.1rem;
    font-weight: 600;
    line-height: 1.55;
    color: var(--text);
    margin: 0 0 10px;
}

.aft-author-bio-text {
    font-size: 0.94rem;
    line-height: 1.7;
    color: var(--text-muted);
    margin: 0;
}

.aft-author-bio-text p {
    margin-bottom: 8px;
}

.aft-author-bio-text p:last-child {
    margin-bottom: 0;
}

/* Right Meta Panel: Share Button + Joined / Member Since */
.aft-author-meta-col {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 22px;
    flex-shrink: 0;
    padding-top: 14px;
}

@media (max-width: 900px) {
    .aft-author-meta-col {
        align-items: center;
        width: 100%;
        margin-top: 8px;
    }
}

.aft-author-share-pill {
    background: linear-gradient(135deg, #4f46e5, #6366f1);
    color: #ffffff;
    border: none;
    border-radius: 9999px;
    padding: 9px 22px;
    font-size: 0.88rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 14px rgba(79, 70, 229, 0.35);
    cursor: pointer;
    transition: all 0.22s ease;
}

.aft-author-share-pill:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(79, 70, 229, 0.45);
    background: linear-gradient(135deg, #4338ca, #4f46e5);
}

.aft-author-share-pill:active {
    transform: translateY(0);
}

.aft-author-member-meta {
    display: flex;
    flex-direction: column;
    gap: 14px;
    border-left: 1px solid var(--border);
    padding-left: 20px;
}

@media (max-width: 900px) {
    .aft-author-member-meta {
        border-left: none;
        flex-direction: row;
        gap: 28px;
        padding-left: 0;
        justify-content: center;
    }
}

.aft-author-meta-item {
    display: flex;
    align-items: center;
    gap: 12px;
    text-align: left;
}

.aft-author-meta-icon {
    width: 34px;
    height: 34px;
    border-radius: 8px;
    background: rgba(99, 102, 241, 0.12);
    color: var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
    flex-shrink: 0;
}

.aft-author-meta-text {
    display: flex;
    flex-direction: column;
}

.aft-author-meta-label {
    font-size: 0.72rem;
    color: var(--text-muted);
    line-height: 1.2;
}

.aft-author-meta-val {
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--text);
    line-height: 1.3;
}

/* ================================================================
   STATS ROW: 3 METRIC CARDS
   ================================================================ */

.aft-author-stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 10px;
}

@media (max-width: 900px) {
    .aft-author-stats-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
}

.aft-author-stat-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 18px 22px;
    display: flex;
    align-items: center;
    gap: 16px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

html.dark-theme .aft-author-stat-card {
    background: rgba(15, 23, 42, 0.65);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.aft-author-stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.05);
}

.aft-author-stat-icon-wrap {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.stat-icon-purple {
    background: #ede9fe;
    color: #7c3aed;
}

html.dark-theme .stat-icon-purple {
    background: rgba(124, 58, 237, 0.22);
    color: #a78bfa;
}

.stat-icon-blue {
    background: #e0f2fe;
    color: #0284c7;
}

html.dark-theme .stat-icon-blue {
    background: rgba(2, 132, 199, 0.22);
    color: #38bdf8;
}

.stat-icon-green {
    background: #dcfce7;
    color: #16a34a;
}

html.dark-theme .stat-icon-green {
    background: rgba(22, 163, 74, 0.22);
    color: #4ade80;
}

.aft-author-stat-details {
    display: flex;
    flex-direction: column;
}

.aft-author-stat-num {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--text);
    line-height: 1.15;
}

.stat-num-green {
    color: #16a34a;
}

html.dark-theme .stat-num-green {
    color: #4ade80;
}

.aft-author-stat-caption {
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--text-muted);
    letter-spacing: 0.05em;
    text-transform: uppercase;
    margin-top: 4px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.stat-info-tooltip {
    font-size: 0.8rem;
    color: var(--text-muted);
    cursor: help;
}

/* ================================================================
   SOCIAL CONNECT SECTION (OFFICIAL BRAND COLORS)
   ================================================================ */

.aft-author-connect-section {
    margin-bottom: 44px;
    padding: 0 4px;
}

@media (max-width: 900px) {
    .aft-author-connect-section {
        text-align: center;
    }
}

.aft-author-connect-heading {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 14px;
    letter-spacing: -0.01em;
}

.aft-author-social-circles {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}

@media (max-width: 900px) {
    .aft-author-social-circles {
        justify-content: center;
    }
}

.aft-social-circle {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
    text-decoration: none;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.12);
    transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.25s ease;
}

.aft-social-circle:hover {
    transform: scale(1.12) translateY(-3px);
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.25);
    color: #ffffff !important;
}

/* Official Brand Color Styling */
.social-linkedin {
    background: #0a66c2;
    color: #ffffff;
}

.social-twitter {
    background: #0f1419;
    color: #ffffff;
}

.social-facebook {
    background: #1877f2;
    color: #ffffff;
}

.social-youtube {
    background: #ff0000;
    color: #ffffff;
}

.social-pinterest {
    background: #e60023;
    color: #ffffff;
}

.social-github {
    background: #24292e;
    color: #ffffff;
}

.social-instagram {
    background: radial-gradient(circle at 30% 107%, #fdf497 0%, #fdf497 5%, #fd5949 45%, #d6249f 60%, #285AEB 90%);
    color: #ffffff;
}

.social-email {
    background: #e0e7ff;
    color: #4338ca;
    border: 1px solid #c7d2fe;
}

html.dark-theme .social-email {
    background: rgba(99, 102, 241, 0.18);
    color: #a5b4fc;
    border: 1px solid rgba(99, 102, 241, 0.35);
}

.social-email:hover {
    background: #4f46e5;
    color: #ffffff !important;
    border-color: #4f46e5;
}

.social-website {
    background: #0284c7;
    color: #ffffff;
}

/* ================================================================
   ARTICLES SECTION (Mockup 2 Feather Accent & Grid)
   ================================================================ */

.aft-author-articles-section {
    margin-top: 12px;
}

.aft-author-articles-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 28px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border);
    position: relative;
}

.aft-author-articles-header::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 64px;
    height: 3px;
    background: linear-gradient(90deg, #8b5cf6, #3b82f6);
    border-radius: 3px;
}

.aft-author-articles-title {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.aft-quill-icon {
    color: #8b5cf6;
    font-size: 1.25rem;
}

.aft-author-articles-count-badge {
    font-size: 0.8rem;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 9999px;
    background: rgba(99, 102, 241, 0.12);
    color: var(--accent);
}

/* Articles Grid */
.aft-author-articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
}

@media (max-width: 640px) {
    .aft-author-articles-grid {
        grid-template-columns: 1fr;
    }
}

/* Empty State */
.aft-author-empty {
    text-align: center;
    padding: 60px 20px;
    background: var(--bg-card);
    border: 1px dashed var(--border);
    border-radius: 18px;
    margin-top: 20px;
}

.aft-author-empty-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: rgba(99, 102, 241, 0.1);
    color: var(--accent);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    margin-bottom: 16px;
}

.aft-author-empty h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text);
    margin: 0 0 8px;
}

.aft-author-empty p {
    font-size: 0.92rem;
    color: var(--text-muted);
    max-width: 440px;
    margin: 0 auto 20px;
    line-height: 1.6;
}

.aft-author-empty-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 22px;
    background: var(--accent);
    color: #ffffff;
    border-radius: 8px;
    text-decoration: none;
    font-size: 0.88rem;
    font-weight: 600;
    transition: background 0.2s ease;
}

.aft-author-empty-btn:hover {
    background: var(--accent-hover);
    color: #ffffff;
}

/* Toast */
.aft-author-toast {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background: #10b981;
    color: #ffffff;
    padding: 12px 20px;
    border-radius: 10px;
    font-size: 0.88rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
    z-index: 999999;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    pointer-events: none;
}

.aft-author-toast.show {
    opacity: 1;
    transform: translateY(0);
}
