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

html {
    scroll-behavior: smooth
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: #111827;
    color: #d1d5db;
    line-height: 1.55
}

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

.header {
    background: #111827;
    border-bottom: 1px solid #1f2937;
    padding: 0 20px;
    position: sticky;
    top: 0;
    z-index: 50
}

.header-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    height: 54px
}

.logo-link {
    display: flex;
    align-items: center;
    gap: 10px
}

.logo-img {
    width: 30px;
    height: 30px;
    border-radius: 7px;
    object-fit: cover
}

.logo-text {
    font-size: 1.05rem;
    font-weight: 700;
    color: #60a5fa
}

.hero {
    text-align: center;
    padding: 2rem 20px .5rem
}

.hero h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #f3f4f6;
    margin-bottom: 5px
}

.hero p {
    color: #6b7280;
    font-size: .92rem;
    max-width: 520px;
    margin: 0 auto
}

.section-nav {
    display: flex;
    justify-content: center;
    gap: 6px;
    padding: 1.2rem 16px .6rem;
    flex-wrap: wrap
}

.section-tab {
    padding: 7px 18px;
    border-radius: 6px;
    background: #1f2937;
    border: 1px solid #374151;
    color: #9ca3af;
    font-size: .84rem;
    font-weight: 500;
    cursor: pointer;
    transition: background .15s, color .15s, border-color .15s;
    font-family: inherit
}

.section-tab:hover {
    color: #d1d5db;
    border-color: #4b5563
}

.section-tab.active {
    background: #2563eb;
    color: #fff;
    border-color: #2563eb
}

.toolbar {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    padding: .4rem 16px 1.1rem;
    flex-wrap: wrap
}

.filter-tab {
    padding: 5px 14px;
    border-radius: 4px;
    background: transparent;
    border: 1px solid #374151;
    color: #6b7280;
    font-size: .78rem;
    font-weight: 500;
    cursor: pointer;
    transition: all .15s;
    font-family: inherit
}

.filter-tab:hover {
    color: #d1d5db;
    border-color: #4b5563
}

.filter-tab.active {
    background: #374151;
    color: #f3f4f6;
    border-color: #4b5563
}

.toolbar-spacer {
    width: 1px;
    height: 18px;
    background: #374151;
    margin: 0 4px
}

.btn-add-custom {
    padding: 5px 14px;
    border-radius: 4px;
    background: #1e3a5f;
    border: 1px solid #2563eb;
    color: #60a5fa;
    font-size: .78rem;
    font-weight: 500;
    cursor: pointer;
    transition: all .15s;
    font-family: inherit
}

.btn-add-custom:hover {
    background: #1e40af;
    color: #fff
}

.cards-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 12px
}

.site-card {
    background: #1f2937;
    border: 1px solid #2d3748;
    border-radius: 10px;
    padding: 16px;
    transition: border-color .15s;
    will-change: transform
}

.site-card:hover {
    border-color: #475569
}

.site-card.pinned {
    border-color: #3b82f6;
    background: #172136
}

.site-card.custom-card {
    border-style: dashed
}

.site-card.custom-card.pinned {
    border-style: solid;
    border-color: #3b82f6
}

.card-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 5px
}

.card-name {
    font-size: .95rem;
    font-weight: 600;
    color: #e5e7eb
}

.card-right {
    display: flex;
    align-items: center;
    gap: 8px
}

.card-badge {
    padding: 2px 8px;
    border-radius: 3px;
    font-size: .68rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .3px
}

.badge-free {
    background: #064e3b;
    color: #6ee7b7
}

.badge-paid {
    background: #4a1d96;
    color: #c4b5fd
}

.badge-custom {
    background: #1e3a5f;
    color: #60a5fa
}

.pin-btn {
    width: 26px;
    height: 26px;
    border-radius: 5px;
    background: transparent;
    border: 1px solid #374151;
    color: #6b7280;
    cursor: pointer;
    font-size: 13px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all .15s;
    position: relative
}

.pin-btn:hover {
    border-color: #4b5563;
    color: #d1d5db
}

.pin-btn.active {
    background: #2563eb;
    border-color: #2563eb;
    color: #fff
}

.pin-rank {
    position: absolute;
    top: -6px;
    right: -6px;
    background: #2563eb;
    color: #fff;
    font-size: 9px;
    font-weight: 700;
    width: 15px;
    height: 15px;
    border-radius: 50%;
    display: none;
    align-items: center;
    justify-content: center;
    line-height: 1
}

.pin-btn.active .pin-rank {
    display: flex
}

.card-desc {
    color: #9ca3af;
    font-size: .82rem;
    margin-bottom: 3px;
    line-height: 1.4
}

.card-license {
    color: #6b7280;
    font-size: .74rem;
    margin-bottom: 12px
}

.btn-visit {
    display: block;
    text-align: center;
    padding: 9px 16px;
    border-radius: 6px;
    background: #2563eb;
    color: #fff;
    font-weight: 500;
    font-size: .82rem;
    transition: background .15s;
    will-change: background-color
}

.btn-visit:hover {
    background: #1d4ed8
}

.card-buttons {
    display: flex;
    gap: 8px;
    align-items: stretch
}

.card-buttons .btn-visit {
    flex: 1
}

.btn-about {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 9px 14px;
    border-radius: 6px;
    background: transparent;
    border: 1px solid #374151;
    color: #6b7280;
    font-weight: 500;
    font-size: .78rem;
    text-decoration: none;
    transition: all .15s;
    white-space: nowrap
}

.btn-about:hover {
    background: #1f2937;
    color: #d1d5db;
    border-color: #4b5563
}

.btn-remove-custom {
    display: block;
    text-align: center;
    margin-top: 6px;
    padding: 6px;
    border-radius: 4px;
    background: transparent;
    border: 1px solid #7f1d1d;
    color: #f87171;
    font-size: .73rem;
    cursor: pointer;
    font-family: inherit;
    width: 100%;
    transition: all .15s
}

.btn-remove-custom:hover {
    background: #7f1d1d;
    color: #fff
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, .6);
    z-index: 100;
    display: none;
    align-items: center;
    justify-content: center
}

.modal-overlay.show {
    display: flex
}

.modal {
    background: #1f2937;
    border: 1px solid #374151;
    border-radius: 12px;
    padding: 24px;
    width: 90%;
    max-width: 420px
}

.modal h2 {
    font-size: 1.05rem;
    color: #f3f4f6;
    margin-bottom: 3px
}

.modal p {
    font-size: .8rem;
    color: #6b7280;
    margin-bottom: 14px
}

.modal label {
    display: block;
    font-size: .78rem;
    color: #9ca3af;
    margin-bottom: 3px;
    font-weight: 500
}

.modal input,
.modal select {
    width: 100%;
    padding: 9px 12px;
    margin-bottom: 10px;
    background: #111827;
    border: 1px solid #374151;
    border-radius: 6px;
    color: #d1d5db;
    font-size: .85rem;
    font-family: inherit
}

.modal input:focus,
.modal select:focus {
    outline: none;
    border-color: #2563eb
}

.modal-btns {
    display: flex;
    gap: 10px;
    margin-top: 4px
}

.modal-btns button {
    flex: 1;
    padding: 9px;
    border-radius: 6px;
    font-size: .85rem;
    font-weight: 500;
    cursor: pointer;
    font-family: inherit
}

.btn-modal-save {
    background: #2563eb;
    border: none;
    color: #fff
}

.btn-modal-save:hover {
    background: #1d4ed8
}

.btn-modal-cancel {
    background: transparent;
    border: 1px solid #374151;
    color: #9ca3af
}

.btn-modal-cancel:hover {
    border-color: #4b5563;
    color: #d1d5db
}

.content-area {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2.5rem 20px 0
}

.content-area h2 {
    font-size: 1.2rem;
    font-weight: 700;
    color: #e5e7eb;
    margin-bottom: 10px
}

.content-area h3 {
    font-size: .95rem;
    font-weight: 600;
    color: #d1d5db;
    margin: 18px 0 6px
}

.content-area p {
    color: #9ca3af;
    font-size: .88rem;
    line-height: 1.7;
    margin-bottom: 10px
}

.content-area ul {
    color: #9ca3af;
    font-size: .88rem;
    line-height: 1.7;
    margin: 0 0 14px 20px
}

.content-area ul li {
    margin-bottom: 4px
}

.content-divider {
    height: 1px;
    background: #1f2937;
    margin: 2rem 0
}

.faq-section {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px 1rem
}

.faq-section h2 {
    font-size: 1.1rem;
    font-weight: 700;
    color: #e5e7eb;
    margin-bottom: 14px
}

.faq-item {
    margin-bottom: 16px
}

.faq-item h3 {
    font-size: .9rem;
    font-weight: 600;
    color: #d1d5db;
    margin-bottom: 4px
}

.faq-item p {
    color: #9ca3af;
    font-size: .85rem;
    line-height: 1.6
}

.footer {
    max-width: 1200px;
    margin: 1.5rem auto 0;
    padding: 1.5rem 20px;
    border-top: 1px solid #1f2937;
    text-align: center
}

.footer-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-bottom: 6px
}

.footer-logo {
    width: 26px;
    height: 26px;
    border-radius: 6px;
    object-fit: cover
}

.footer-name {
    font-size: .95rem;
    font-weight: 700;
    color: #60a5fa
}

.footer p {
    color: #4b5563;
    font-size: .78rem;
    margin-bottom: 3px
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-top: 10px
}

.footer-links a {
    color: #6b7280;
    font-size: .8rem
}

.footer-links a:hover {
    color: #60a5fa
}

.no-results {
    text-align: center;
    padding: 3rem 1rem;
    color: #4b5563;
    font-size: .9rem
}

@media(max-width:640px) {
    .cards-grid {
        grid-template-columns: 1fr
    }

    .hero h1 {
        font-size: 1.25rem
    }

    .content-area {
        padding: 2rem 16px 0
    }
}