/* Typography & Base */
.saas-featured-card, .saas-cat-card, .saas-dir-layout, .saas-hs-wrap {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: #111;
}

/* Horizontal Scroll */
.saas-hs-wrap {
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding-bottom: 20px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}
.saas-hs-wrap::-webkit-scrollbar { display: none; }
.saas-hs-track {
    display: flex;
    gap: 20px;
    width: max-content;
    min-height: 350px;
    padding: 10px 0; /* Better shadow breathing room */
}

/* Featured Card */
.saas-featured-card {
    width: 320px;
    background: #fff;
    border: 1px solid #eaeaea;
    border-radius: 12px;
    padding: 25px;
    min-height: 320px; /* Consistent height */
    box-shadow: 0 4px 20px rgba(0,0,0,0.02);
    display: flex;
    flex-direction: column;
    scroll-snap-align: start;
    flex-shrink: 0;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.saas-featured-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.06);
    border-color: #ddd;
}
.saas-fc-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}
.saas-fc-header img {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    object-fit: cover;
    border: 1px solid #f0f0f0;
}
.saas-fc-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 700;
}
.saas-fc-desc {
    margin: 0 0 15px 0;
    font-size: 14px;
    color: #555;
    line-height: 1.5;
    flex-grow: 1;
}
.saas-fc-tag {
    display: inline-block;
    background: #f8f9fa;
    border: 1px solid #eee;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    color: #666;
    margin-bottom: 15px;
    align-self: flex-start;
}
.saas-fc-rating {
    font-size: 14px;
    margin-bottom: 20px;
    color: #fbbf24;
}
.saas-fc-rating strong {
    color: #111;
    margin-left: 5px;
}
.saas-btn {
    display: block;
    text-align: center;
    border: 1px solid #ddd;
    background: #fff;
    color: #111;
    padding: 12px;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    transition: 0.2s;
    font-size: 14px;
}
.saas-btn:hover {
    border-color: #ff3b30;
    color: #ff3b30;
}
.saas-btn-red {
    display: inline-block;
    background: #ff3b30;
    color: #fff;
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    font-size: 14px;
    transition: 0.2s;
    border: none;
}
.saas-btn-red:hover {
    background: #e6352b;
    color: #fff;
}

/* Category Grid */
.saas-cat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 24px;
}
.saas-cat-card {
    background: #fff;
    border: 1px solid #eaeaea;
    border-radius: 12px;
    padding: 30px 20px;
    text-align: center;
    transition: 0.2s;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0,0,0,0.01);
}
.saas-cat-card:hover {
    border-color: #ddd;
    box-shadow: 0 8px 20px rgba(0,0,0,0.04);
}
.saas-cat-icon {
    font-size: 32px;
    margin-bottom: 15px;
}
.saas-cat-card h4 {
    margin: 0 0 5px 0;
    font-size: 15px;
    font-weight: 700;
}
.saas-cat-card p {
    margin: 0;
    font-size: 13px;
    color: #888;
}

/* Directory Layout */
.saas-dir-layout {
    display: flex;
    gap: 40px;
    align-items: flex-start;
}
.saas-sidebar {
    width: 260px;
    flex-shrink: 0;
}
.saas-filter-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}
.saas-filter-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 700;
}
.saas-clear {
    font-size: 13px;
    color: #666;
    text-decoration: none;
}
.saas-filter {
    margin-bottom: 30px;
}
.saas-filter h4 {
    margin: 0 0 15px 0;
    font-size: 14px;
    font-weight: 700;
}
.saas-filter label {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    color: #444;
    margin-bottom: 12px;
    cursor: pointer;
}
.saas-filter input[type="checkbox"] {
    display: none;
}
.cb-custom {
    width: 18px;
    height: 18px;
    border: 1px solid #ccc;
    border-radius: 4px;
    display: inline-block;
    position: relative;
    transition: 0.2s;
}
.saas-filter input[type="checkbox"]:checked + .cb-custom {
    background: #ff3b30;
    border-color: #ff3b30;
}
.saas-filter input[type="checkbox"]:checked + .cb-custom::after {
    content: '';
    position: absolute;
    left: 6px;
    top: 2px;
    width: 4px;
    height: 9px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

/* List Main Area */
.saas-main-list {
    flex-grow: 1;
}
.saas-list-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    font-size: 14px;
    color: #666;
}
.saas-list-header select {
    border: 1px solid #eaeaea;
    padding: 8px 15px;
    border-radius: 6px;
    background: #fff;
    outline: none;
    font-size: 14px;
    cursor: pointer;
}
.saas-list-table-header {
    display: flex;
    align-items: center;
    padding: 15px 20px;
    border-bottom: 1px solid #eaeaea;
    font-size: 13px;
    font-weight: 600;
    color: #555;
}
.col-tool { flex: 3; display: flex; gap: 15px; align-items: center; }
.col-cat { flex: 1.5; }
.col-rating { flex: 1.5; }
.col-price { flex: 1.5; }
.col-action { flex: 1.5; display: flex; justify-content: flex-end; gap: 10px; align-items: center; }

/* List Items */
.saas-list-items {
    min-height: 500px;
    display: flex;
    flex-direction: column;
}
.saas-list-item {
    display: flex;
    align-items: center;
    padding: 25px 20px;
    border-bottom: 1px solid #f5f5f5;
    background: #fff;
    transition: 0.2s;
}
.saas-list-item:hover {
    background: #fafafa;
}
.col-tool img {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    border: 1px solid #f0f0f0;
    object-fit: cover;
}
.col-tool-info h3 {
    margin: 0 0 5px 0;
    font-size: 16px;
    font-weight: 700;
}
.col-tool-info p {
    margin: 0;
    font-size: 13px;
    color: #666;
    line-height: 1.4;
}
.saas-list-tag {
    background: #f8f9fa;
    border: 1px solid #eee;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    color: #555;
}
.col-rating strong {
    font-size: 14px;
    color: #111;
}
.col-rating .stars {
    font-size: 12px;
    color: #fbbf24;
    margin-left: 5px;
}
.col-price strong {
    font-size: 14px;
    color: #111;
    display: block;
    margin-bottom: 3px;
}
.col-price .price-sub {
    font-size: 12px;
    color: #888;
}
.saas-btn-bookmark {
    background: transparent;
    border: 1px solid #ddd;
    width: 38px;
    height: 38px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #555;
    transition: 0.2s;
}
.saas-btn-bookmark:hover {
    border-color: #ff3b30;
    color: #ff3b30;
}
.saas-load-more {
    text-align: center;
    margin-top: 30px;
}
.saas-load-more button {
    background: #fff;
    border: 1px solid #ddd;
    padding: 10px 25px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.2s;
}
.saas-load-more button:hover {
    background: #f9f9f9;
}

/* Responsive */
/* Responsive Polish */
@media(max-width: 1200px) {
    .saas-container { max-width: 100%; padding: 0 30px; }
}

@media(max-width: 1024px) {
    .saas-hero-inner { flex-direction: column; text-align: center; gap: 40px; }
    .saas-hero-content p { margin: 0 auto 40px; }
    .saas-hero-search { margin: 0 auto 20px; }
    .saas-hero-tags { justify-content: center; }
    .saas-hero-stats { justify-content: center; }
    .saas-compare-grid, .saas-bestof-grid { grid-template-columns: repeat(2, 1fr); }
    .saas-list-table-header { display: none; }
    .saas-list-item { flex-wrap: wrap; gap: 15px; }
    .col-tool { flex: 100%; }
    .col-cat, .col-rating, .col-price { flex: 1; }
    .col-action { flex: 100%; justify-content: center; margin-top: 15px; }
}

@media(max-width: 768px) {
    .saas-header-inner { flex-direction: column; gap: 15px; }
    .saas-nav { display: none; }
    .saas-dir-layout { flex-direction: column; }
    .saas-sidebar { width: 100%; border-right: none; border-bottom: 1px solid #eee; padding-bottom: 30px; }
    .saas-hero-content h1 { font-size: 32px; }
    .saas-compare-grid, .saas-bestof-grid { grid-template-columns: 1fr; }
    
    /* Footer Responsive */
    .saas-footer-final .container { 
        grid-template-columns: 1fr !important; 
        text-align: center;
    }
    .footer-head::after { left: 50%; transform: translateX(-50%); }
    .footer-list li { justify-content: center; }
    .footer-social-icon { margin: 0 auto; }
    .footer-feat { border-right: none !important; border-bottom: 1px solid #1a1a1a; padding: 20px 0 !important; }
}

/* Layout & Sections */
body { 
    margin: 0; 
    background: #fafafa; 
    font-family: 'Inter', sans-serif; 
    zoom: 0.8; /* Thu nhỏ toàn bộ web 80% */
    -moz-transform: scale(0.8);
    -moz-transform-origin: top center;
}
.saas-container { max-width: 1600px; margin: 0 auto; padding: 0 40px; } /* Tăng max-width để khi zoom 80% nó vẫn rộng rãi */
.saas-section { padding: 40px 0; }
.saas-header-inner { display: flex; justify-content: space-between; align-items: center; padding: 2px 0; min-height: 40px; }
.saas-sticky-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 9999;
    background: #000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.3);
}
.saas-logo { font-size: 18px !important; }
.saas-nav a, .saas-nav li a { color: #fff !important; text-decoration: none; font-size: 14px !important; font-weight: 600; }
body { padding-top: 50px !important; } 
body.admin-bar { padding-top: 82px !important; } 
.saas-btn-red { padding: 6px 15px !important; font-size: 12px !important; }
.saas-header-actions { gap: 10px !important; }
.saas-header-actions svg, .saas-header-actions i { font-size: 14px !important; }
.saas-header-actions { display: flex; align-items: center; gap: 15px; }
.saas-btn-dark { background: #111; color: #fff; padding: 10px 20px; border-radius: 8px; text-decoration: none; font-size: 14px; font-weight: 600; }

/* Hero */
.saas-hero { background: #fff; padding: 80px 0 60px; border-bottom: 1px solid #eee; }
.saas-hero-inner { display: flex; align-items: center; gap: 50px; }
.saas-hero-content { flex: 1; }
.hero-tagline { color: #ff3b30; font-weight: 700; font-size: 12px; letter-spacing: 1px; text-transform: uppercase; margin-bottom: 15px; }
.saas-hero-content h1 { font-size: 48px; font-weight: 800; line-height: 1.1; margin: 0 0 20px 0; letter-spacing: -1px; color: #111; }
.saas-hero-content p { font-size: 18px; color: #555; margin: 0 0 40px 0; line-height: 1.5; max-width: 500px; }

.saas-hero-search { display: flex; max-width: 550px; background: #fff; border: 1px solid #ddd; border-radius: 8px; padding: 5px; margin-bottom: 20px; box-shadow: 0 4px 15px rgba(0,0,0,0.05); }
.saas-hero-search input { flex: 1; border: none; padding: 10px 20px; outline: none; font-size: 16px; }
.saas-hero-search button { border: none; cursor: pointer; padding: 12px 25px; border-radius: 6px; font-size: 15px; }

.saas-hero-tags { display: flex; align-items: center; gap: 10px; font-size: 13px; margin-bottom: 50px; flex-wrap: wrap; }
.saas-hero-tags strong { color: #111; }
.saas-hero-tags a { background: #f5f5f5; color: #555; text-decoration: none; padding: 5px 12px; border-radius: 20px; font-weight: 500; }

.saas-hero-stats { display: flex; gap: 30px; }
.stat-item { font-size: 13px; color: #666; line-height: 1.4; }
.stat-item strong { color: #ff3b30; font-size: 18px; }
.stat-item .icon { font-size: 20px; margin-bottom: 5px; display: block; }

.saas-hero-graphic { flex: 1; position: relative; }
.graphic-card { background: #fff; border: 1px solid #eee; border-radius: 12px; padding: 20px; box-shadow: 0 20px 40px rgba(0,0,0,0.08); width: 280px; margin: 0 auto; transform: rotate(2deg); }
.graphic-card img { width: 100%; height: 150px; object-fit: cover; border-radius: 8px; margin-bottom: 15px; }
.graphic-info h4 { margin: 0 0 5px 0; font-size: 18px; }
.graphic-info p { margin: 0 0 10px 0; font-size: 13px; color: #666; }
.graphic-info .btn-mock { background: #111; color: #fff; text-align: center; padding: 10px; border-radius: 8px; font-size: 13px; font-weight: 600; margin-top: 10px; }

/* Compare Grid */
.saas-compare-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.compare-card { background: #fff; border: 1px solid #eaeaea; border-radius: 12px; padding: 25px; text-align: center; transition: 0.2s; }
.compare-card:hover { border-color: #ddd; box-shadow: 0 10px 20px rgba(0,0,0,0.03); transform: translateY(-3px); }
.compare-logos { display: flex; align-items: center; justify-content: center; gap: 10px; margin-bottom: 15px; }
.compare-logos img { width: 40px; height: 40px; border-radius: 8px; border: 1px solid #eee; }
.compare-logos .vs { font-size: 12px; font-weight: 800; color: #ff3b30; }
.compare-names { font-size: 15px; font-weight: 700; margin-bottom: 20px; }
.compare-names span { color: #888; font-weight: 400; font-size: 12px; margin: 0 5px; }
.saas-btn-light { display: block; border: 1px solid #eaeaea; color: #111; padding: 10px; border-radius: 8px; font-size: 13px; font-weight: 600; text-decoration: none; }

/* Best Of */
.saas-bestof-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.bestof-card { background: #fff; border: 1px solid #eaeaea; border-radius: 12px; padding: 20px; display: flex; align-items: center; gap: 15px; font-weight: 600; font-size: 14px; cursor: pointer; transition: 0.2s; }
.bestof-card:hover { border-color: #ff3b30; }
.bestof-card .icon { font-size: 24px; background: #f8f9fa; padding: 10px; border-radius: 10px; }
.bestof-card .arrow { margin-left: auto; color: #aaa; }

/* Bottom Section */
.saas-bottom-section { display: flex; gap: 40px; padding: 60px 0; }
.saas-newsletter { flex: 1; background: #111; border-radius: 20px; padding: 40px; color: #fff; display: flex; position: relative; overflow: hidden; }
.nl-content { position: relative; z-index: 2; max-width: 400px; }
.nl-content h2 { font-size: 28px; margin: 0 0 15px 0; }
.nl-content p { color: #aaa; margin: 0 0 25px 0; line-height: 1.5; }
.nl-form { display: flex; gap: 10px; margin-bottom: 15px; }
.nl-form input { flex: 1; padding: 12px 15px; border-radius: 8px; border: none; outline: none; }
.nl-form button { padding: 12px 25px; border-radius: 8px; }
.nl-spam { font-size: 12px; color: #666; }
.nl-graphic { position: absolute; right: -20px; bottom: -20px; font-size: 150px; opacity: 0.5; }

.saas-latest-reviews { flex: 1; }
.review-list { display: flex; flex-direction: column; gap: 15px; }
.review-item { display: flex; align-items: center; gap: 15px; background: #fff; padding: 15px; border-radius: 12px; border: 1px solid #eaeaea; }
.review-item img { width: 50px; height: 50px; border-radius: 8px; border: 1px solid #eee; }
.review-item h4 { margin: 0; font-size: 14px; flex: 1; font-weight: 600; }
.review-item .tag { background: #f8f9fa; padding: 4px 10px; border-radius: 12px; font-size: 11px; color: #555; }
.review-item .date { font-size: 12px; color: #888; }
