/* =============================================
   Custom overrides for Fluid theme
   =============================================
   Only defines styles NOT provided by the theme.
   Keep lean - let the theme do the heavy lifting.
   ============================================= */

/* --- Link base reset --- */
a { text-decoration: none; color: inherit; }

/* --- Badge chips --- */
.badge {
    display: inline-block;
    padding: 2px 8px;
    font-size: 0.75rem;
    border-radius: 4px;
    font-weight: 600;
    white-space: nowrap;
}
.badge.new   { background: #e7f5ff; color: #1c7ed6; }
.badge.stopped { background: #fff5f5; color: #fa5252; }

/* --- Button styles (used across pages) --- */
.btn {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 0.82rem;
    font-weight: 500;
    text-decoration: none;
    white-space: nowrap;
    margin-right: 4px;
    margin-bottom: 2px;
    transition: opacity 0.15s;
}
.btn:hover { opacity: 0.85; }

.btn-fast   { background: #2563eb; color: #fff; }
.btn-backup { background: #475569; color: #fff; }
.btn-github { background: #000;    color: #fff; }
.btn-store  { background: #000;    color: #fff; border-radius: 16px; padding: 4px 14px; }

/* Primary CTA button (used in airport detail posts) — matches btn-fast style */
/* Use higher specificity to override theme's .markdown-body .btn rule */
.btn-primary-cta,
.markdown-body .btn-primary-cta,
.markdown-body a.btn.btn-primary-cta {
    background: #2563eb !important;
    color: #fff !important;
}
.btn-primary-cta:hover,
.markdown-body a.btn.btn-primary-cta:hover {
    opacity: 0.85;
    background: #1d4ed8 !important;
    color: #fff !important;
}
.btn-large {
    padding: 4px 12px;
}

/* --- Download table (used on /download page) --- */
.download-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    border: 1px solid #e9ecef;
}
.download-table th,
.download-table td {
    padding: 0.55rem 1rem;
    text-align: left;
    border-bottom: 1px solid #e9ecef;
    font-size: 0.9rem;
    vertical-align: middle;
}
.download-table th {
    background: #f8f9fa;
    font-weight: 600;
    color: #495057;
}
.download-table tr:last-child td { border-bottom: none; }

/* --- Download page section header --- */
.download-section-title {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin-bottom: 0.75rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #e9ecef;
}
.download-section-title h2 { font-size: 1.25rem; margin: 0; }

/* --- Download tab quick-jump nav --- */
.download-tab-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    padding: 0.75rem;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}
.download-tab-nav a {
    padding: 5px 14px;
    background: #fff;
    border: 1px solid #dee2e6;
    border-radius: 16px;
    font-size: 0.85rem;
    font-weight: 500;
    color: #495057;
    text-decoration: none;
    transition: all 0.15s;
    white-space: nowrap;
}
.download-tab-nav a:hover {
    background: #2563eb;
    color: #fff;
    border-color: #2563eb;
}

/* --- Homepage airport ranking table --- */
.airport-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    border: 1px solid #e1e7ef;
    border-radius: 8px;
    overflow: hidden;
    font-size: 0.9rem;
}
.airport-table thead tr {
    background: linear-gradient(90deg, #1e3a5f 0%, #2563eb 100%);
    color: #fff;
}
.airport-table th {
    padding: 0.65rem 0.9rem;
    font-weight: 600;
    text-align: left;
    white-space: nowrap;
}
.airport-table td {
    padding: 0.65rem 0.9rem;
    border-bottom: 1px solid #f0f3f8;
    vertical-align: middle;
}
.airport-table tbody tr:hover td { background: #f5f8ff; }
.airport-table tbody tr:last-child td { border-bottom: none; }

.rank-top { color: #2563eb; font-weight: 700; font-size: 0.85rem; }

/* --- Airport detail sections on homepage --- */
.airport-section {
    border: 1px solid #e1e7ef;
    border-radius: 8px;
    margin-bottom: 1.5rem;
    overflow: hidden;
}
.airport-section-hd {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    background: #f5f8ff;
    border-bottom: 1px solid #e1e7ef;
}
.airport-section-hd h3 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 700;
    color: #1a202c;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}
.airport-section-hd .tags span {
    font-size: 0.75rem;
    padding: 1px 8px;
    border-radius: 10px;
    margin-left: 4px;
    font-weight: 500;
}
.tag-line     { background: #dbeafe; color: #1d4ed8; }
.tag-protocol { background: #d1fae5; color: #065f46; }
.price-tag {
    background: #eff6ff;
    color: #2563eb;
    padding: 4px 10px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 0.9rem;
}
.airport-section-bd {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
}
.airport-intro  { grid-column: 1 / -1; padding: 1rem 1.25rem 0; }
.airport-features { padding: 1rem 1.25rem; }
.airport-pricing  { padding: 1rem 1.25rem; border-left: 1px solid #f0f3f8; }
.airport-intro p, .airport-features p { font-size: 0.9rem; color: #4b5563; line-height: 1.7; margin-bottom: 0.5rem; }
.airport-section h4 { font-size: 0.9rem; font-weight: 600; margin-bottom: 0.5rem; color: #374151; }
.airport-features ul { list-style: none; padding: 0; margin: 0; }
.airport-features li { font-size: 0.87rem; color: #374151; padding: 0.3rem 0; border-bottom: 1px dashed #f0f0f0; }
.airport-features li:last-child { border-bottom: none; }

/* Price table (compact) */
.price-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.83rem;
}
.price-table th {
    background: #f1f5f9;
    color: #475569;
    padding: 0.35rem 0.6rem;
    text-align: left;
    font-weight: 600;
    font-size: 0.78rem;
}
.price-table td {
    padding: 0.35rem 0.6rem;
    border-bottom: 1px solid #f1f5f9;
    color: #374151;
}
.price-table tr:last-child td { border-bottom: none; }

.airport-section-ft {
    padding: 0.75rem 1.25rem;
    background: #fafafa;
    border-top: 1px solid #f0f0f0;
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    align-items: center;
}

/* Coupon highlight */
.coupon-box {
    background: #fef9c3;
    border: 1px solid #fde047;
    border-radius: 6px;
    padding: 0.4rem 0.75rem;
    font-size: 0.85rem;
    color: #713f12;
    display: inline-block;
    margin-top: 0.4rem;
}

/* --- Alert/info box used in posts --- */
.alert-box {
    background: #fff3cd;
    color: #856404;
    padding: 0.75rem 1rem;
    border-radius: 6px;
    margin-bottom: 1rem;
    border: 1px solid #ffeeba;
    font-size: 0.9rem;
}

/* Tips block used on homepage */
.tips-block {
    background: #f8fafc;
    border-left: 4px solid #2563eb;
    border-radius: 0 8px 8px 0;
    padding: 1rem 1.25rem;
    font-size: 0.9rem;
    line-height: 1.8;
    color: #374151;
}

/* --- Responsive --- */
@media (max-width: 768px) {
    .airport-section-bd { grid-template-columns: 1fr; }
    .airport-pricing { border-left: none; border-top: 1px solid #f0f3f8; }
    .airport-section-hd { flex-direction: column; align-items: flex-start; }
    .download-table { font-size: 0.8rem; }
    .download-table th, .download-table td { padding: 0.4rem 0.6rem; }
}