/**
 * metin2kayit.com — Eteria Design Language Extensions
 * Custom styles for Metin2 Kayıt:
 *  - Official Golden Check Badge (.rohan-mirror-check) (Rule #5)
 *  - 4-Step Registration Grid (.ld-steps-grid)
 *  - 10 Error Troubleshooting Hub (.ld-errors-grid, .ld-err-card)
 *  - Security Specs Plaque (.ld-sec-table)
 *  - Interactive FAQ Accordion (.ld-faq-item)
 */

/* ==================== RULE #5: OFFICIAL ROHAN GOLDEN CHECK BADGE ==================== */
.rohan-mirror-check {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 35%, #ffd98a 0%, #b88636 70%, #825b1e 100%);
    border: 1px solid #e5b66b;
    color: #2b1803;
    font-size: 10px;
    font-weight: 900;
    line-height: 1;
    box-shadow: 0 0 8px rgba(229, 182, 107, 0.45);
    flex-shrink: 0;
    vertical-align: middle;
}
.rohan-mirror-check svg,
.rohan-mirror-check i {
    color: #2b1803;
    font-size: 10px;
}

/* ==================== 4-STEP REGISTRATION GRID ==================== */
.ld-steps-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: clamp(1rem, 1.8vw, 1.5rem);
    margin-top: 2rem;
}
.ld-step-card {
    position: relative;
    padding: clamp(1.4rem, 2vw, 1.8rem);
    border: 1px solid rgba(231, 193, 132, 0.2);
    background: linear-gradient(180deg, rgba(32, 25, 19, 0.95) 0%, rgba(17, 13, 10, 0.98) 100%);
    box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.9);
    transition: transform 0.25s ease, border-color 0.25s ease;
}
.ld-step-card:hover {
    transform: translateY(-4px);
    border-color: rgba(231, 193, 132, 0.45);
}
.ld-step-num {
    font-family: "bm-euljiro-latin", "Manrope", serif;
    font-size: 1.8rem;
    color: var(--ld-gold, #e7c184);
    line-height: 1;
    margin-bottom: 0.6rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.ld-step-title {
    font-family: "bm-euljiro-latin", "Manrope", serif;
    font-size: 1.05rem;
    color: #fff;
    margin: 0 0 0.5rem;
    letter-spacing: 0.02em;
}
.ld-step-text {
    font-size: 0.88rem;
    line-height: 1.55;
    color: rgba(255, 255, 255, 0.72);
    margin: 0;
}

/* ==================== 10 REGISTRATION ERROR HUB ==================== */
.ld-search-wrapper {
    position: relative;
    margin-bottom: 1.5rem;
}
.ld-search-input {
    width: 100%;
    padding: 0.9rem 1.2rem;
    padding-left: 2.8rem;
    border-radius: 4px;
    background: rgba(18, 14, 11, 0.9);
    border: 1px solid rgba(231, 193, 132, 0.35);
    color: #fff;
    font-family: "Manrope", sans-serif;
    font-size: 0.95rem;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.ld-search-input:focus {
    border-color: var(--ld-gold, #e7c184);
    box-shadow: 0 0 12px rgba(231, 193, 132, 0.25);
}
.ld-search-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--ld-gold, #e7c184);
    opacity: 0.7;
    pointer-events: none;
}
.ld-errors-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}
.ld-err-card {
    position: relative;
    padding: 1.25rem 1.4rem;
    border: 1px solid rgba(231, 193, 132, 0.18);
    background: linear-gradient(180deg, rgba(26, 20, 15, 0.92) 0%, rgba(15, 12, 9, 0.96) 100%);
    border-radius: 4px;
    transition: border-color 0.2s ease, background 0.2s ease;
}
.ld-err-card:hover {
    border-color: rgba(231, 193, 132, 0.4);
    background: linear-gradient(180deg, rgba(34, 26, 20, 0.96) 0%, rgba(20, 15, 11, 0.98) 100%);
}
.ld-err-card.is-hidden {
    display: none !important;
}
.ld-err-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}
.ld-err-code {
    font-family: "bm-euljiro-latin", "Manrope", monospace;
    font-size: 0.8rem;
    letter-spacing: 0.08em;
    color: #ff7d7d;
    background: rgba(255, 100, 100, 0.12);
    border: 1px solid rgba(255, 100, 100, 0.25);
    padding: 2px 8px;
    border-radius: 3px;
}
.ld-err-card h3 {
    font-family: "bm-euljiro-latin", "Manrope", serif;
    font-size: 1rem;
    color: #ffe5a3;
    margin: 0 0 0.4rem;
}
.ld-err-card p {
    font-size: 0.86rem;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.78);
    margin: 0;
}
.ld-err-card p strong {
    color: #fff;
}

/* ==================== SECURITY SPECS TABLE ==================== */
.ld-sec-table-wrap {
    overflow-x: auto;
    margin-top: 1.5rem;
}
.ld-sec-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
    text-align: left;
}
.ld-sec-table th,
.ld-sec-table td {
    padding: 0.85rem 1rem;
    border-bottom: 1px solid rgba(231, 193, 132, 0.14);
}
.ld-sec-table th {
    font-family: "bm-euljiro-latin", "Manrope", serif;
    color: var(--ld-gold, #e7c184);
    letter-spacing: 0.06em;
    background: rgba(255, 255, 255, 0.03);
}
.ld-sec-table td {
    color: rgba(255, 255, 255, 0.82);
}
.ld-sec-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #ffe5a3;
    font-weight: 600;
}

/* ==================== FAQ ACCORDION ==================== */
.ld-faq-list {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    margin-top: 2rem;
}
.ld-faq-item {
    border: 1px solid rgba(231, 193, 132, 0.18);
    background: linear-gradient(180deg, rgba(26, 20, 15, 0.88) 0%, rgba(15, 12, 9, 0.94) 100%);
    border-radius: 4px;
    overflow: hidden;
    transition: border-color 0.2s ease;
}
.ld-faq-item[open] {
    border-color: rgba(231, 193, 132, 0.45);
}
.ld-faq-summary {
    padding: 1rem 1.4rem;
    cursor: pointer;
    font-family: "bm-euljiro-latin", "Manrope", serif;
    font-size: 1.02rem;
    color: #ffe5a3;
    display: flex;
    align-items: center;
    justify-content: space-between;
    list-style: none;
    user-select: none;
}
.ld-faq-summary::-webkit-details-marker {
    display: none;
}
.ld-faq-icon {
    transition: transform 0.2s ease;
    color: var(--ld-gold, #e7c184);
}
.ld-faq-item[open] .ld-faq-icon {
    transform: rotate(180deg);
}
.ld-faq-body {
    padding: 0 1.4rem 1.2rem;
    font-size: 0.9rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.78);
    border-top: 1px solid rgba(231, 193, 132, 0.08);
    padding-top: 0.8rem;
}

/* ==================== SERVER DATES BADGES ==================== */
.ld-server-badges-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1rem;
}
.ld-srv-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    background: rgba(231, 193, 132, 0.08);
    border: 1px solid rgba(231, 193, 132, 0.24);
    border-radius: 999px;
    font-size: 0.84rem;
    color: #ffe5a3;
}

/* ==================== RESPONSIVE ADAPTATION ==================== */
@media (max-width: 1024px) {
    .ld-steps-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 640px) {
    .ld-steps-grid,
    .ld-errors-grid {
        grid-template-columns: 1fr;
    }
    .ld-server-badges-row {
        flex-direction: column;
    }
}


/* ==================== SECTION: EDITORIAL CODEX & ARTICLES GRID ==================== */
.ld-article-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
    margin: 2rem auto 2.2rem;
    max-width: 980px;
}
.ld-article-tab {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 18px;
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    color: rgba(255, 255, 255, 0.72);
    background: rgba(26, 20, 15, 0.75);
    border: 1px solid rgba(231, 193, 132, 0.22);
    border-radius: 999px;
    cursor: pointer;
    transition: all 0.22s cubic-bezier(0.4, 0, 0.2, 1);
    user-select: none;
}
.ld-article-tab:hover {
    color: #fff;
    border-color: rgba(231, 193, 132, 0.5);
    background: rgba(45, 34, 25, 0.9);
    transform: translateY(-1px);
}
.ld-article-tab.is-active {
    color: #1a1005;
    background: linear-gradient(135deg, #ffd98a 0%, #e5b66b 50%, #c4933f 100%);
    border-color: #ffd98a;
    box-shadow: 0 4px 15px rgba(229, 182, 107, 0.35);
}

/* Articles Grid - Fully Expanded Downward, NO SCROLLBAR */
.ld-articles-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    margin-top: 1.5rem;
}
.ld-article-card {
    position: relative;
    background: linear-gradient(180deg, rgba(26, 20, 15, 0.94) 0%, rgba(15, 12, 9, 0.98) 100%);
    border: 1px solid rgba(231, 193, 132, 0.2);
    border-radius: 6px;
    padding: clamp(1.4rem, 2.2vw, 2rem);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: transform 0.28s cubic-bezier(0.4, 0, 0.2, 1),
                border-color 0.28s cubic-bezier(0.4, 0, 0.2, 1),
                box-shadow 0.28s cubic-bezier(0.4, 0, 0.2, 1);
}
.ld-article-card:hover {
    transform: translateY(-3px);
    border-color: rgba(231, 193, 132, 0.55);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.6), 0 0 18px rgba(229, 182, 107, 0.15);
}
.ld-article-card.is-hidden {
    display: none !important;
}

.ld-article-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 0.9rem;
}
.ld-article-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #ffe5a3;
    background: rgba(231, 193, 132, 0.12);
    border: 1px solid rgba(231, 193, 132, 0.28);
}
.ld-article-readtime {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.52);
}
.ld-article-readtime svg {
    opacity: 0.7;
}

.ld-article-title {
    font-family: var(--ld-font-heading, "bm-euljiro-latin", serif);
    font-size: clamp(1.15rem, 1.4vw, 1.35rem);
    color: #fff;
    line-height: 1.35;
    margin: 0 0 0.75rem 0;
    letter-spacing: 0.01em;
}
.ld-article-card:hover .ld-article-title {
    color: #ffe5a3;
}
.ld-article-lead {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.74);
    line-height: 1.62;
    margin-bottom: 1.25rem;
}

.ld-article-checklist {
    list-style: none;
    padding: 0;
    margin: 0 0 1.25rem 0;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}
.ld-article-checklist li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 0.86rem;
    line-height: 1.55;
    color: rgba(255, 255, 255, 0.86);
}
.ld-article-checklist li strong {
    color: #ffe5a3;
}
.ld-article-checklist li code {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 3px;
    padding: 1px 5px;
    font-size: 0.82em;
    color: #ffd98a;
}

.ld-article-tip {
    background: rgba(231, 193, 132, 0.06);
    border-left: 3px solid #e5b66b;
    border-radius: 0 4px 4px 0;
    padding: 0.85rem 1.1rem;
    font-size: 0.82rem;
    line-height: 1.55;
    color: #f3dfc8;
    margin-bottom: 1.25rem;
}
.ld-article-tip strong {
    color: #ffd98a;
}

.ld-article-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-top: 1px solid rgba(231, 193, 132, 0.1);
    padding-top: 1rem;
    margin-top: auto;
}
.ld-article-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.82rem;
    font-weight: 600;
    color: #ffe5a3;
    text-decoration: none;
    transition: color 0.2s ease, gap 0.2s ease;
}
.ld-article-link:hover {
    color: #fff;
    gap: 10px;
}
.ld-article-official-tag {
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.42);
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

/* Responsive Grid Adaptation */
@media (max-width: 900px) {
    .ld-articles-grid {
        grid-template-columns: 1fr;
    }
    .ld-article-tabs {
        justify-content: flex-start;
        overflow-x: auto;
        padding-bottom: 0.5rem;
        flex-wrap: nowrap;
    }
}

/* ==================== ERGONOMIC DISCORD BUTTON & FLOATING BADGE ==================== */
.ld-nav-discord-link {
    display: inline-flex !important;
    align-items: center;
    gap: 7px;
    padding: 6px 14px;
    background: rgba(88, 101, 242, 0.16);
    border: 1px solid rgba(88, 101, 242, 0.42);
    border-radius: 999px;
    color: #ffffff !important;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-decoration: none;
    white-space: nowrap;
    flex-shrink: 0;
    transition: all 0.22s ease;
}
.ld-nav-discord-link:hover {
    background: #5865F2;
    border-color: #5865F2;
    color: #ffffff !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(88, 101, 242, 0.45);
}
.ld-nav-disc-svg {
    fill: currentColor;
    flex-shrink: 0;
}
.ld-nav-disc-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #57F287;
    box-shadow: 0 0 6px #57F287;
    flex-shrink: 0;
}

/* Floating Discord Community Badge */
.ld-float-discord-wrap {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 999;
}
.ld-float-discord {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 18px 8px 10px;
    background: linear-gradient(135deg, rgba(28, 22, 16, 0.94) 0%, rgba(14, 11, 8, 0.98) 100%);
    border: 1px solid rgba(231, 193, 132, 0.35);
    border-radius: 999px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.65), 0 0 18px rgba(88, 101, 242, 0.22);
    text-decoration: none;
    backdrop-filter: blur(8px);
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1),
                border-color 0.25s ease,
                box-shadow 0.25s ease;
}
.ld-float-discord:hover {
    transform: translateY(-3px) scale(1.02);
    border-color: rgba(231, 193, 132, 0.7);
    box-shadow: 0 14px 35px rgba(0, 0, 0, 0.75), 0 0 24px rgba(88, 101, 242, 0.45);
}
.ld-float-disc-icon-box {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: #5865F2;
    color: #fff;
    flex-shrink: 0;
    box-shadow: 0 0 12px rgba(88, 101, 242, 0.6);
}
.ld-float-disc-icon-box svg {
    fill: currentColor;
}
.ld-float-disc-body {
    display: flex;
    flex-direction: column;
    line-height: 1.25;
}
.ld-float-disc-title {
    font-size: 0.82rem;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: 0.02em;
}
.ld-float-disc-meta {
    font-size: 0.72rem;
    font-weight: 600;
    color: #57F287;
    display: flex;
    align-items: center;
    gap: 5px;
}
.ld-float-disc-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #57F287;
    box-shadow: 0 0 6px #57F287;
    animation: ld-dot-pulse 2s infinite ease-in-out;
}
@keyframes ld-dot-pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.3); opacity: 0.6; }
}
@media (max-width: 640px) {
    .ld-float-discord {
        padding: 6px 12px 6px 8px;
        gap: 8px;
        bottom: 16px;
        right: 16px;
    }
    .ld-float-disc-title {
        font-size: 0.75rem;
    }
    .ld-float-disc-meta {
        font-size: 0.68rem;
    }
}

/* ==================== ROHAN2 LOGO OPTIMIZATIONS ==================== */
.ld-brand img {
    height: 46px !important;
    width: auto !important;
    max-width: 140px;
    object-fit: contain;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.65));
}
.ld-footer-brand img {
    height: 52px !important;
    width: auto !important;
    max-width: 160px;
    object-fit: contain;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.65));
}
.ld-wordmark img {
    width: 100%;
    height: auto;
    object-fit: contain;
    filter: drop-shadow(0 15px 35px rgba(0, 0, 0, 0.7));
}
.ld-wordmark-sheen {
    -webkit-mask-image: url("../img/logo_main.webp") !important;
    mask-image: url("../img/logo_main.webp") !important;
    -webkit-mask-size: contain;
    mask-size: contain;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-position: center;
    mask-position: center;
}
