/* ================================================
   SCISOVELAB - COMPLETE BEAUTIFUL STYLES
   ================================================ */

/* ------------------------------------------------
   CALCULATOR GRID LAYOUT
   ------------------------------------------------ */
.ssl-section-wrap {
    margin: 60px 0;
    padding: 0 10px;
}

.ssl-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 35px;
    padding-bottom: 18px;
    border-bottom: 3px solid #F1F5F9;
}

.ssl-section-title {
    font-size: 30px;
    font-weight: 800;
    color: #0F172A;
    margin: 0;
    letter-spacing: -0.5px;
}

.ssl-section-title.center {
    text-align: center;
    width: 100%;
    margin-bottom: 35px;
}

.ssl-view-all {
    font-size: 15px;
    color: #2563EB;
    text-decoration: none;
    font-weight: 600;
    white-space: nowrap;
    background: #EFF6FF;
    padding: 8px 18px;
    border-radius: 20px;
    transition: all 0.3s;
}

.ssl-view-all:hover {
    background: #2563EB;
    color: white;
}

/* ------------------------------------------------
   GRID COLUMNS
   ------------------------------------------------ */
.ssl-calc-grid {
    display: grid;
    gap: 28px;
}

.ssl-columns-1 { grid-template-columns: repeat(1, 1fr); }
.ssl-columns-2 { grid-template-columns: repeat(2, 1fr); }
.ssl-columns-3 { grid-template-columns: repeat(3, 1fr); }
.ssl-columns-4 { grid-template-columns: repeat(4, 1fr); }

/* ------------------------------------------------
   CALCULATOR CARD - MAIN STYLES
   ------------------------------------------------ */
.ssl-calc-card {
    background: #ffffff;
    border: 2px solid #E2E8F0;
    border-radius: 20px;
    padding: 35px 28px 28px 28px;
    text-align: center;
    transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 280px;
    cursor: pointer;
}

/* Top colored line on each card */
.ssl-calc-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg, #2563EB, #7C3AED);
    opacity: 0;
    transition: opacity 0.3s;
}

.ssl-calc-card:hover::before {
    opacity: 1;
}

/* Hover Effect */
.ssl-calc-card:hover {
    border-color: #C7D7FD;
    transform: translateY(-10px);
    box-shadow:
        0 4px 6px rgba(37, 99, 235, 0.05),
        0 20px 50px rgba(37, 99, 235, 0.15);
}

/* Background pattern on hover */
.ssl-calc-card::after {
    content: '';
    position: absolute;
    bottom: -40px;
    right: -40px;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: rgba(37, 99, 235, 0.04);
    transition: all 0.4s;
}

.ssl-calc-card:hover::after {
    transform: scale(2);
    background: rgba(37, 99, 235, 0.06);
}

/* ------------------------------------------------
   CATEGORY BADGE (top right of card)
   ------------------------------------------------ */
.ssl-card-badge {
    position: absolute;
    top: 16px;
    right: 16px;
    color: white;
    font-size: 10px;
    font-weight: 700;
    padding: 5px 12px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.8px;
}

/* ------------------------------------------------
   CARD ICON
   ------------------------------------------------ */
.ssl-card-icon {
    font-size: 58px;
    margin-bottom: 18px;
    display: block;
    line-height: 1;
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.1));
    transition: transform 0.3s;
}

.ssl-calc-card:hover .ssl-card-icon {
    transform: scale(1.15) rotate(-5deg);
}

/* ------------------------------------------------
   CARD TITLE
   ------------------------------------------------ */
.ssl-card-title {
    font-size: 18px;
    font-weight: 700;
    color: #0F172A;
    margin: 0 0 10px 0;
    line-height: 1.3;
    transition: color 0.3s;
}

.ssl-calc-card:hover .ssl-card-title {
    color: #2563EB;
}

/* ------------------------------------------------
   CARD DESCRIPTION
   ------------------------------------------------ */
.ssl-card-desc {
    font-size: 14px;
    color: #64748B;
    margin: 0 0 22px 0;
    line-height: 1.7;
    flex: 1;
}

/* ------------------------------------------------
   CARD BUTTON
   ------------------------------------------------ */
.ssl-card-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: white;
    padding: 11px 26px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    letter-spacing: 0.3px;
    margin-top: auto;
    position: relative;
    z-index: 1;
}

.ssl-card-btn:hover {
    color: white;
    transform: scale(1.06);
    box-shadow: 0 6px 20px rgba(0,0,0,0.2);
    text-decoration: none;
}

/* ------------------------------------------------
   CATEGORY CARDS SECTION
   ------------------------------------------------ */
.ssl-cat-section {
    margin: 60px 0;
}

.ssl-cat-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 22px;
}

/* ------------------------------------------------
   CATEGORY CARD
   ------------------------------------------------ */
.ssl-cat-card {
    border-radius: 20px;
    padding: 40px 25px;
    text-align: center;
    text-decoration: none;
    transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    overflow: hidden;
    border: 2px solid transparent;
}

.ssl-cat-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 50px rgba(0,0,0,0.15);
    background: var(--hover-color) !important;
    border-color: transparent;
}

.ssl-cat-card:hover .ssl-cat-name {
    color: white !important;
}

.ssl-cat-card:hover .ssl-cat-count {
    color: rgba(255,255,255,0.85) !important;
}

.ssl-cat-icon {
    font-size: 56px;
    margin-bottom: 16px;
    display: block;
    transition: transform 0.3s;
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.1));
}

.ssl-cat-card:hover .ssl-cat-icon {
    transform: scale(1.2);
}

.ssl-cat-name {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 8px;
    transition: color 0.3s;
    color: #0F172A;
}

.ssl-cat-count {
    font-size: 13px;
    color: #64748B;
    transition: color 0.3s;
    font-weight: 500;
}

/* Count badge */
.ssl-cat-count-badge {
    display: inline-block;
    background: rgba(255,255,255,0.5);
    padding: 3px 12px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    margin-top: 8px;
    transition: all 0.3s;
}

.ssl-cat-card:hover .ssl-cat-count-badge {
    background: rgba(255,255,255,0.3);
    color: white;
}

/* ------------------------------------------------
   LOAD MORE BUTTON
   ------------------------------------------------ */
.ssl-center {
    text-align: center;
    margin-top: 45px;
}

.ssl-load-more {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: transparent;
    color: #2563EB;
    border: 2px solid #2563EB;
    padding: 14px 40px;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s;
    letter-spacing: 0.3px;
}

.ssl-load-more:hover {
    background: #2563EB;
    color: white;
    box-shadow: 0 8px 25px rgba(37, 99, 235, 0.3);
    transform: translateY(-2px);
}

/* ------------------------------------------------
   NO RESULTS
   ------------------------------------------------ */
.ssl-no-results {
    text-align: center;
    color: #94A3B8;
    padding: 60px 40px;
    font-size: 16px;
    background: #F8FAFC;
    border-radius: 16px;
    border: 2px dashed #E2E8F0;
}

/* ------------------------------------------------
   CALCULATOR WRAPPER (single post)
   ------------------------------------------------ */
.ssl-calculator-wrap {
    background: white;
    border-radius: 20px;
    border: 2px solid #E2E8F0;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
    margin: 30px 0;
}

/* ------------------------------------------------
   ANIMATIONS
   ------------------------------------------------ */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.ssl-calc-card {
    animation: fadeInUp 0.5s ease both;
}

.ssl-calc-card:nth-child(1) { animation-delay: 0.05s; }
.ssl-calc-card:nth-child(2) { animation-delay: 0.10s; }
.ssl-calc-card:nth-child(3) { animation-delay: 0.15s; }
.ssl-calc-card:nth-child(4) { animation-delay: 0.20s; }
.ssl-calc-card:nth-child(5) { animation-delay: 0.25s; }
.ssl-calc-card:nth-child(6) { animation-delay: 0.30s; }

/* ------------------------------------------------
   RESPONSIVE
   ------------------------------------------------ */
@media (max-width: 1200px) {
    .ssl-columns-4 { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 1024px) {
    .ssl-columns-3,
    .ssl-columns-4 { grid-template-columns: repeat(2, 1fr); }
    .ssl-cat-grid  { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    .ssl-section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    .ssl-section-title { font-size: 24px; }
    .ssl-columns-2,
    .ssl-columns-3,
    .ssl-columns-4 { grid-template-columns: repeat(2, 1fr); }
    .ssl-calc-grid  { gap: 16px; }
    .ssl-calc-card  { padding: 25px 18px; min-height: 240px; }
    .ssl-card-icon  { font-size: 44px; }
    .ssl-card-title { font-size: 16px; }
}

@media (max-width: 560px) {
    .ssl-columns-2,
    .ssl-columns-3,
    .ssl-columns-4 { grid-template-columns: 1fr; }
    .ssl-cat-grid  { grid-template-columns: repeat(2, 1fr); }
    .ssl-calc-card { min-height: auto; }
}

@media (max-width: 380px) {
    .ssl-cat-grid  { grid-template-columns: 1fr; }
}