/* ============================================================
   yz.org.tr - Frontend CSS — Premium Dark Theme
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

:root {
    --bg-primary: #f8fafc;
    --bg-secondary: #ffffff;
    --bg-card: #ffffff;
    --bg-card-hover: #f1f5f9;
    --accent: #6C5CE7;
    --accent-light: #5243d6;
    --accent-glow: rgba(108, 92, 231, 0.12);
    --cyan: #00A3A6;
    --cyan-glow: rgba(0, 163, 166, 0.08);
    --pink: #d63384;
    --orange: #d97706;
    --green: #16a34a;
    --text-primary: #1e293b;
    --text-secondary: #475569;
    --text-muted: #64748b;
    --border: rgba(108, 92, 231, 0.15);
    --border-light: rgba(0, 0, 0, 0.08);
    --gradient-primary: linear-gradient(135deg, #6C5CE7, #a855f7, #00A3A6);
    --gradient-card: linear-gradient(145deg, rgba(108,92,231,0.03), rgba(0,163,166,0.01));
    --radius: 16px;
    --radius-sm: 10px;
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.04);
    --shadow-glow: 0 10px 45px rgba(108, 92, 231, 0.1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Inter', -apple-system, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.7;
    overflow-x: hidden;
}

a { color: var(--accent-light); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--cyan); }

/* ── Navbar ───────────────────────────────── */
.navbar-yz {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    padding: 12px 0;
    position: sticky; top: 0; z-index: 100;
}
.navbar-yz .navbar-brand {
    font-weight: 800; font-size: 1.4rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}
.navbar-yz .nav-link {
    color: var(--text-secondary); font-weight: 500; font-size: 0.92rem;
    padding: 8px 16px; border-radius: 8px; transition: all 0.2s;
}
.navbar-yz .nav-link:hover, .navbar-yz .nav-link.active {
    color: var(--accent); background: rgba(108, 92, 231, 0.08);
}
.search-box {
    background: var(--bg-secondary); border: 1px solid var(--border);
    border-radius: 50px; overflow: hidden; display: flex; max-width: 320px;
}
.search-box input {
    background: transparent; border: none; color: var(--text-primary); padding: 8px 16px;
    outline: none; font-size: 0.9rem; width: 100%;
}
.search-box button {
    background: var(--accent); border: none; color: #fff;
    padding: 8px 18px; cursor: pointer; transition: background 0.2s;
}
.search-box button:hover { background: var(--accent-light); }

/* ── Hero Section ─────────────────────────── */
.hero {
    padding: 100px 0 80px;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.hero::before {
    content: ''; position: absolute; top: -50%; left: -50%;
    width: 200%; height: 200%;
    background: radial-gradient(ellipse at 30% 50%, rgba(108,92,231,0.08) 0%, transparent 50%),
                radial-gradient(ellipse at 70% 50%, rgba(0,206,209,0.06) 0%, transparent 50%);
    animation: heroGlow 8s ease-in-out infinite alternate;
}
@keyframes heroGlow {
    0% { transform: translate(0, 0); }
    100% { transform: translate(-3%, 2%); }
}
.hero h1 {
    font-size: 3.2rem; font-weight: 800; position: relative;
    background: var(--gradient-primary);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    margin-bottom: 20px;
}
.hero p {
    font-size: 1.15rem; color: var(--text-secondary);
    max-width: 650px; margin: 0 auto 40px; position: relative;
}

/* ── Stats Bar ────────────────────────────── */
.stats-bar {
    display: flex; justify-content: center; gap: 50px;
    position: relative; margin-bottom: 20px;
}
.stat-item {
    text-align: center;
}
.stat-item .stat-num {
    font-size: 2rem; font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}
.stat-item .stat-lbl { font-size: 0.85rem; color: var(--text-muted); }

/* ── Section Titles ───────────────────────── */
.section-title {
    font-size: 1.8rem; font-weight: 700; margin-bottom: 12px;
    display: flex; align-items: center; gap: 12px;
}
.section-title i { color: var(--accent); }
.section-subtitle { color: var(--text-secondary); margin-bottom: 32px; }

section.content-section { padding: 70px 0; }
section.content-section:nth-child(even) { background: var(--bg-secondary); }

/* ── Tool Card ────────────────────────────── */
.tool-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    transition: all 0.3s ease;
    height: 100%;
    display: flex; flex-direction: column;
    position: relative; overflow: hidden;
}
.tool-card::before {
    content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
    background: var(--gradient-primary); opacity: 0; transition: opacity 0.3s;
}
.tool-card:hover {
    transform: translateY(-4px);
    border-color: var(--accent);
    box-shadow: var(--shadow-glow);
}
.tool-card:hover::before { opacity: 1; }

.tool-card .tool-logo {
    width: 56px; height: 56px; border-radius: 14px;
    background: var(--gradient-card); display: flex;
    align-items: center; justify-content: center;
    margin-bottom: 16px; font-size: 1.5rem; color: var(--accent);
}
.tool-card .tool-logo img { width: 100%; height: 100%; object-fit: cover; border-radius: 14px; }
.tool-card h3 { font-size: 1.1rem; font-weight: 600; margin-bottom: 8px; }
.tool-card h3 a { color: var(--text-primary); }
.tool-card h3 a:hover { color: var(--accent-light); }
.tool-card p { font-size: 0.88rem; color: var(--text-secondary); flex: 1; margin-bottom: 16px; }
.tool-card .tool-meta {
    display: flex; justify-content: space-between; align-items: center;
    border-top: 1px solid var(--border-light); padding-top: 14px;
}
.tool-card .rating { font-size: 0.8rem; color: var(--orange); }
.tool-card .views { font-size: 0.78rem; color: var(--text-muted); }

/* ── Prompt Card ──────────────────────────── */
.prompt-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    transition: all 0.3s ease;
    height: 100%;
    position: relative;
}
.prompt-card:hover {
    border-color: var(--cyan);
    box-shadow: 0 0 30px var(--cyan-glow);
    transform: translateY(-3px);
}
.prompt-card .prompt-tool {
    display: inline-block; font-size: 0.75rem; font-weight: 600;
    padding: 4px 12px; border-radius: 50px;
    background: rgba(0,206,209,0.12); color: var(--cyan);
    margin-bottom: 12px;
}
.prompt-card h3 { font-size: 1rem; font-weight: 600; margin-bottom: 10px; }
.prompt-card h3 a { color: var(--text-primary); }
.prompt-card .prompt-text {
    font-size: 0.85rem; color: var(--text-secondary);
    background: var(--bg-primary); border-radius: var(--radius-sm);
    padding: 14px; margin-bottom: 14px;
    font-family: 'Courier New', monospace;
    max-height: 100px; overflow: hidden;
    border: 1px solid var(--border-light);
}
.prompt-card .prompt-actions {
    display: flex; justify-content: space-between; align-items: center;
}
.btn-copy {
    background: var(--accent); color: #fff; border: none;
    padding: 7px 18px; border-radius: 8px; font-size: 0.82rem;
    font-weight: 600; cursor: pointer; transition: all 0.2s;
    display: flex; align-items: center; gap: 6px;
}
.btn-copy:hover { background: var(--accent-light); transform: scale(1.03); }
.btn-copy.copied { background: var(--green); }
.copy-count { font-size: 0.78rem; color: var(--text-muted); }

/* ── Dictionary ───────────────────────────── */
.letter-nav {
    display: flex; flex-wrap: wrap; gap: 6px;
    margin-bottom: 30px; justify-content: center;
}
.letter-nav a {
    width: 40px; height: 40px; display: flex;
    align-items: center; justify-content: center;
    border-radius: 10px; font-weight: 700; font-size: 0.95rem;
    background: var(--bg-card); color: var(--text-secondary);
    border: 1px solid var(--border); transition: all 0.2s;
}
.letter-nav a:hover, .letter-nav a.active {
    background: var(--accent); color: #fff; border-color: var(--accent);
}

.term-card {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 20px; margin-bottom: 16px;
    transition: all 0.2s;
}
.term-card:hover { border-color: var(--accent); }
.term-card h3 { font-size: 1.1rem; font-weight: 600; color: var(--accent-light); margin-bottom: 8px; }
.term-card p { font-size: 0.9rem; color: var(--text-secondary); margin: 0; }

/* ── Badges ───────────────────────────────── */
.badge-free { background: rgba(0,184,148,0.15); color: var(--green); padding: 4px 12px; border-radius: 50px; font-size: 0.75rem; font-weight: 600; }
.badge-freemium { background: rgba(253,203,110,0.15); color: var(--orange); padding: 4px 12px; border-radius: 50px; font-size: 0.75rem; font-weight: 600; }
.badge-paid { background: rgba(253,121,168,0.15); color: var(--pink); padding: 4px 12px; border-radius: 50px; font-size: 0.75rem; font-weight: 600; }
.badge-tag {
    background: rgba(108,92,231,0.1); color: var(--accent-light);
    padding: 4px 12px; border-radius: 50px; font-size: 0.75rem;
    font-weight: 500; border: 1px solid rgba(108,92,231,0.2);
    transition: all 0.2s;
}
.badge-tag:hover { background: rgba(108,92,231,0.25); color: #fff; }

/* ── Buttons ──────────────────────────────── */
.btn-gradient {
    background: var(--gradient-primary); color: #fff;
    border: none; padding: 12px 32px; border-radius: 50px;
    font-weight: 600; font-size: 0.95rem;
    transition: all 0.3s; cursor: pointer;
    box-shadow: 0 4px 20px var(--accent-glow);
}
.btn-gradient:hover {
    transform: translateY(-2px); color: #fff;
    box-shadow: 0 8px 30px var(--accent-glow);
}
.btn-outline-yz {
    border: 1px solid var(--border); color: var(--text-secondary);
    padding: 8px 20px; border-radius: 50px; font-weight: 500;
    background: transparent; transition: all 0.2s;
}
.btn-outline-yz:hover, .btn-outline-yz.active {
    border-color: var(--accent); color: var(--accent); background: rgba(108,92,231,0.08);
}

/* ── Filter Bar ───────────────────────────── */
.filter-bar {
    display: flex; flex-wrap: wrap; gap: 10px;
    align-items: center; margin-bottom: 30px;
    padding: 16px 20px; background: var(--bg-card);
    border-radius: var(--radius); border: 1px solid var(--border);
}

/* ── Newsletter ───────────────────────────── */
.newsletter-section {
    background: var(--gradient-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 50px 40px; text-align: center;
}
.newsletter-section h3 { font-size: 1.5rem; font-weight: 700; margin-bottom: 10px; }
.newsletter-section p { color: var(--text-secondary); margin-bottom: 24px; }
.newsletter-form { display: flex; gap: 10px; max-width: 460px; margin: 0 auto; }
.newsletter-form input {
    flex: 1; background: var(--bg-primary); border: 1px solid var(--border);
    color: var(--text-primary); padding: 12px 20px; border-radius: 50px; outline: none;
    font-size: 0.9rem;
}
.newsletter-form input:focus { border-color: var(--accent); }

/* ── Footer ───────────────────────────────── */
.footer-yz {
    background: var(--bg-secondary); border-top: 1px solid var(--border);
    padding: 60px 0 30px;
}
.footer-brand {
    font-size: 1.3rem; font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}
.footer-yz h5 { font-size: 0.9rem; font-weight: 600; color: var(--text-primary); margin-bottom: 16px; }
.footer-yz ul { list-style: none; padding: 0; }
.footer-yz ul li { margin-bottom: 8px; }
.footer-yz ul li a { color: var(--text-secondary); font-size: 0.88rem; }
.footer-yz ul li a:hover { color: var(--accent-light); }
.footer-bottom {
    border-top: 1px solid var(--border-light); margin-top: 40px;
    padding-top: 20px; text-align: center;
    font-size: 0.82rem; color: var(--text-muted);
}

/* ── Page Header ──────────────────────────── */
.page-hero {
    padding: 60px 0 40px; text-align: center;
    background: var(--bg-secondary); border-bottom: 1px solid var(--border);
}
.page-hero h1 { font-size: 2.2rem; font-weight: 800; margin-bottom: 10px; }
.page-hero p { color: var(--text-secondary); font-size: 1rem; }

/* ── Detail Page ──────────────────────────── */
.detail-header {
    display: flex; gap: 24px; align-items: flex-start;
    margin-bottom: 32px;
}
.detail-logo {
    width: 80px; height: 80px; border-radius: 20px;
    background: var(--gradient-card); display: flex;
    align-items: center; justify-content: center; font-size: 2.5rem;
    color: var(--accent); flex-shrink: 0;
}
.detail-logo img { width: 100%; height: 100%; object-fit: cover; border-radius: 20px; }

/* ── Pagination ───────────────────────────── */
.pagination .page-link {
    background: var(--bg-card); border: 1px solid var(--border);
    color: var(--text-secondary); border-radius: 8px; margin: 0 3px;
}
.pagination .page-link:hover { background: var(--accent); color: #fff; border-color: var(--accent); }
.pagination .page-item.active .page-link {
    background: var(--accent); border-color: var(--accent); color: #fff;
}

/* ── Submit Form ──────────────────────────── */
.submit-form .form-control, .submit-form .form-select {
    background: var(--bg-primary); border: 1px solid var(--border);
    color: var(--text-primary); border-radius: var(--radius-sm);
    padding: 12px 16px;
}
.submit-form .form-control:focus, .submit-form .form-select:focus {
    border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-glow);
}
.submit-form .form-label { color: var(--text-secondary); font-weight: 500; }

/* ── Dark Theme Global Fixes ─────────────── */
.form-control, .form-select {
    background: var(--bg-primary) !important;
    border: 1px solid var(--border) !important;
    color: var(--text-primary) !important;
}
.form-control:focus, .form-select:focus {
    border-color: var(--accent) !important;
    box-shadow: 0 0 0 3px var(--accent-glow) !important;
    color: var(--text-primary) !important;
}
.form-control::placeholder { color: var(--text-muted) !important; }
.form-label { color: var(--text-secondary) !important; font-weight: 500; }
.alert { border-radius: var(--radius-sm); font-size: 0.9rem; }
.alert-custom { background: var(--bg-card); border: 1px solid var(--border); color: var(--text-primary); margin-bottom: 20px; padding: 14px 20px; }
.alert-success.alert-custom { border-left: 4px solid var(--green); }
.alert-danger.alert-custom { border-left: 4px solid var(--pink); }
.alert-success { background: rgba(0,184,148,0.1); border-color: rgba(0,184,148,0.3); color: var(--green); }
.alert-danger { background: rgba(253,121,168,0.1); border-color: rgba(253,121,168,0.3); color: var(--pink); }
.alert-warning { background: rgba(253,203,110,0.1); border-color: rgba(253,203,110,0.3); color: var(--orange); }
.dropdown-menu { background: var(--bg-card) !important; border: 1px solid var(--border) !important; }
.dropdown-item { color: var(--text-secondary) !important; }
.dropdown-item:hover, .dropdown-item:focus { background: rgba(108,92,231,0.12) !important; color: var(--text-primary) !important; }
.nav-tabs { border-color: var(--border) !important; }
.nav-tabs .nav-link { color: var(--text-secondary) !important; background: transparent !important; border-color: transparent !important; transition: all 0.2s; }
.nav-tabs .nav-link:hover { border-color: var(--border) !important; color: var(--text-primary) !important; }
.nav-tabs .nav-link.active { color: var(--accent-light) !important; background: var(--bg-card) !important; border-color: var(--border) var(--border) var(--bg-card) !important; }
.badge { font-weight: 500; }
.text-muted { color: var(--text-muted) !important; }
.text-success { color: var(--green) !important; }
.text-danger { color: var(--pink) !important; }
h1, h2, h3, h4, h5, h6 { color: var(--text-primary); }

/* ── Vote Panel (Detail Page) ────────────── */
.vote-panel {
    display: flex; flex-direction: column; align-items: center; gap: 4px;
    padding: 16px 8px; background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); min-width: 60px;
}
.vote-btn {
    background: none; border: none; cursor: pointer; font-size: 1.3rem;
    transition: all 0.2s; padding: 4px;
}
.vote-btn:hover { transform: scale(1.2); }
.vote-score { font-size: 1.2rem; font-weight: 700; }

/* ── Detail Sidebar ──────────────────────── */
.detail-sidebar {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 24px; position: sticky; top: 80px;
}

/* ── Comment Section ─────────────────────── */
.comment-form-wrapper {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 20px; margin-bottom: 24px;
}
.comment-login-prompt {
    text-align: center; padding: 20px; background: var(--bg-card);
    border: 1px solid var(--border); border-radius: var(--radius);
    margin-bottom: 24px; color: var(--text-muted);
}
.no-comments-msg {
    color: var(--text-muted); text-align: center; padding: 30px;
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius);
}
.no-comments-msg p { margin-top: 8px; }

/* ── Community Toolbar ───────────────────── */
.community-toolbar {
    display: flex; justify-content: space-between; align-items: center;
    flex-wrap: wrap; gap: 12px; margin-bottom: 24px;
    padding: 12px 20px; background: var(--bg-card);
    border: 1px solid var(--border); border-radius: var(--radius);
}
.sort-tabs { display: flex; gap: 4px; flex-wrap: wrap; }
.sort-tab {
    padding: 8px 18px; border-radius: 50px; font-size: 0.88rem; font-weight: 500;
    color: var(--text-secondary); background: transparent; text-decoration: none;
    border: 1px solid transparent; transition: all 0.2s;
}
.sort-tab:hover { color: var(--text-primary); background: rgba(108,92,231,0.08); }
.sort-tab.active {
    color: var(--accent-light); background: rgba(108,92,231,0.15);
    border-color: var(--accent);
}

/* ── Reddit-Style Cards ──────────────────── */
.community-feed { display: flex; flex-direction: column; gap: 12px; }
.reddit-card {
    display: flex; gap: 0; background: var(--bg-card);
    border: 1px solid var(--border); border-radius: var(--radius);
    overflow: hidden; transition: all 0.2s;
}
.reddit-card:hover { border-color: var(--accent); box-shadow: var(--shadow-glow); }
.reddit-vote-col {
    display: flex; flex-direction: column; align-items: center; gap: 2px;
    padding: 16px 10px; background: var(--bg-primary); min-width: 52px;
    border-right: 1px solid var(--border-light);
}
.vote-btn-community {
    background: none; border: none; cursor: pointer; font-size: 1.2rem;
    padding: 4px; transition: all 0.15s;
}
.vote-btn-community:hover { transform: scale(1.25); }
.vote-score-community { font-size: 1rem; font-weight: 700; }
.reddit-content-col { flex: 1; padding: 16px 20px; min-width: 0; }
.reddit-meta {
    display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
    margin-bottom: 8px; font-size: 0.8rem;
}
.reddit-author {
    color: var(--text-muted); text-decoration: none;
    display: flex; align-items: center; gap: 4px;
}
.reddit-author:hover { color: var(--accent-light); }
.reddit-avatar { width: 18px; height: 18px; border-radius: 50%; object-fit: cover; }
.reddit-time { color: var(--text-muted); }
.reddit-title { font-size: 1.05rem; font-weight: 600; margin-bottom: 6px; }
.reddit-title a { color: var(--text-primary); text-decoration: none; }
.reddit-title a:hover { color: var(--accent-light); }
.reddit-purpose { font-size: 0.85rem; color: var(--text-secondary); margin-bottom: 8px; }
.reddit-prompt-preview {
    font-family: 'Courier New', monospace; font-size: 0.84rem;
    color: var(--text-secondary); background: var(--bg-primary);
    padding: 12px; border-radius: var(--radius-sm); margin-bottom: 10px;
    max-height: 80px; overflow: hidden; line-height: 1.6;
    border: 1px solid var(--border-light);
}
.reddit-image-preview {
    margin-bottom: 10px; border-radius: var(--radius-sm); overflow: hidden;
    max-height: 300px;
}
.reddit-image-preview img {
    width: 100%; height: auto; max-height: 300px; object-fit: cover;
    border-radius: var(--radius-sm);
}
.reddit-actions {
    display: flex; gap: 12px; align-items: center; flex-wrap: wrap;
    padding-top: 8px; border-top: 1px solid var(--border-light);
}
.reddit-action-btn {
    font-size: 0.8rem; color: var(--text-muted); background: none;
    border: none; cursor: pointer; text-decoration: none;
    display: flex; align-items: center; gap: 4px; padding: 4px 8px;
    border-radius: 6px; transition: all 0.15s;
}
.reddit-action-btn:hover { color: var(--text-primary); background: rgba(108, 92, 231, 0.08); }

/* ── Image Upload Zone ───────────────────── */
.image-upload-zone {
    border: 2px dashed var(--border); border-radius: var(--radius);
    padding: 30px; text-align: center; cursor: pointer;
    transition: all 0.2s; background: var(--bg-primary);
}
.image-upload-zone:hover, .image-upload-zone.dragover {
    border-color: var(--accent); background: rgba(108,92,231,0.05);
}
.upload-placeholder { display: flex; flex-direction: column; align-items: center; }
.upload-preview {
    position: relative; display: flex; justify-content: center;
    align-items: center;
}
.upload-preview img {
    max-height: 250px; max-width: 100%; border-radius: var(--radius-sm);
    object-fit: contain;
}
.upload-remove {
    position: absolute; top: 8px; right: 8px; width: 32px; height: 32px;
    border-radius: 50%; background: rgba(253,121,168,0.9); color: #fff;
    border: none; cursor: pointer; font-size: 0.9rem;
    display: flex; align-items: center; justify-content: center;
    transition: all 0.2s;
}
.upload-remove:hover { background: var(--pink); transform: scale(1.1); }

/* ── Animations ───────────────────────────── */
@keyframes fadeInUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
.animate-in { animation: fadeInUp 0.5s ease forwards; }

/* ── Responsive ───────────────────────────── */
@media (max-width: 768px) {
    .hero h1 { font-size: 2rem; }
    .stats-bar { gap: 24px; }
    .stat-item .stat-num { font-size: 1.5rem; }
    .newsletter-form { flex-direction: column; }
    .detail-header { flex-direction: column; align-items: center; text-align: center; }
    .filter-bar { flex-direction: column; }
    .community-toolbar { flex-direction: column; align-items: stretch; }
    .sort-tabs { justify-content: center; }
    .reddit-card { flex-direction: column; }
    .reddit-vote-col { flex-direction: row; padding: 10px 16px; min-width: unset; }
}
