/* =========================================
   GST Calculator Tool - PREMIUM UI
   Version: 1.0 | AI-Style Neon Theme
   Mobile-First | AdSense Optimized
   ========================================= */

:root,
[data-theme="dark"] {
    --primary-blue: #1b98e0;
    --secondary-green: #32de84;
    --accent-purple: #9b59b6;
    --bg-primary: #0a0a14;
    --bg-secondary: #121220;
    --bg-tertiary: #1a1a2e;
    --bg-card: rgba(18, 18, 32, 0.9);
    --text-primary: #ffffff;
    --text-secondary: #e0e0e0;
    --text-muted: #cbd5e1;
    --border-color: #3a476a;
    --glass-bg: rgba(18, 18, 32, 0.85);
    --glass-border: rgba(255, 255, 255, 0.1);
    --gradient-primary: linear-gradient(135deg, #1b98e0, #9b59b6);
    --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.5);
}

[data-theme="light"] {
    --primary-blue: #0066cc;
    --bg-primary: #f8fafc;
    --bg-secondary: #ffffff;
    --bg-tertiary: #f1f5f9;
    --bg-card: rgba(255, 255, 255, 0.95);
    --text-primary: #1e293b;
    --text-secondary: #334155;
    --text-muted: #64748b;
    --border-color: #e2e8f0;
    --glass-bg: rgba(255, 255, 255, 0.9);
    --glass-border: rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.1);
}

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

body {
    font-family: 'Poppins', sans-serif;
    background: var(--bg-primary);
    color: var(--text-secondary);
    line-height: 1.7;
    min-height: 100vh;
}

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

p,
.seo-text,
.feature-desc,
.brand-desc {
    text-align: justify;
    text-justify: inter-word;
}

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    transition: opacity 0.4s ease;
}

.loader {
    width: 50px;
    height: 50px;
    border: 4px solid var(--border-color);
    border-top-color: var(--primary-blue);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

#particles-js {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.cosmic-stars {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -2;
}

.aurora-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at 50% 0%, rgba(27, 152, 224, 0.15) 0%, transparent 50%), radial-gradient(ellipse at 80% 50%, rgba(155, 89, 182, 0.1) 0%, transparent 40%);
    pointer-events: none;
    z-index: -3;
}

/* Header */
.ultra-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    background: rgba(10, 10, 20, 0.9);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
    padding: 12px 0;
}

[data-theme="light"] .ultra-header {
    background: rgba(255, 255, 255, 0.95);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.header-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.header-brand img {
    width: 45px;
    height: 45px;
    border-radius: 50%;
}

.h-brand-name {
    font-size: 1.5rem;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 25px;
}

.u-nav-list {
    display: flex;
    list-style: none;
    gap: 20px;
}

.u-link {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

.u-link:hover {
    color: var(--primary-blue);
}

.u-theme-btn {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: 1px solid var(--border-color);
    background: var(--bg-tertiary);
    color: var(--text-primary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.u-theme-btn:hover {
    background: var(--primary-blue);
    border-color: var(--primary-blue);
    color: #fff;
}


.header-spacer {
    height: 75px;
}

/* Tool Layout */
.tool-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 30px;
    padding: 30px 0;
}

/* Sidebar */
.sidebar {
    position: sticky;
    top: 100px;
    height: fit-content;
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 25px;
}

.sidebar h3 {
    font-size: 1.1rem;
    color: var(--text-primary);
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--border-color);
    display: flex;
    align-items: center;
    gap: 10px;
}

.sidebar h3 i {
    color: var(--primary-blue);
}

.tool-list {
    list-style: none;
}

.tool-list li {
    margin-bottom: 8px;
}

.tool-list a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    color: var(--text-muted);
    text-decoration: none;
    transition: all 0.3s;
    font-size: 0.9rem;
}

.tool-list a:hover,
.tool-list a.active {
    background: linear-gradient(90deg, rgba(27, 152, 224, 0.15), transparent);
    color: var(--primary-blue);
    border-color: var(--primary-blue);
    transform: translateX(5px);
}

.tool-list a i {
    width: 20px;
    text-align: center;
}

/* Tool Card */
.tool-content {
    min-width: 0;
}

.tool-card {
    background: linear-gradient(165deg, rgba(18, 22, 38, 0.98) 0%, rgba(12, 15, 28, 0.99) 100%);
    border: 1px solid rgba(27, 152, 224, 0.25);
    border-radius: 32px;
    padding: 40px 35px;
    margin-bottom: 30px;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.5), 0 0 60px rgba(27, 152, 224, 0.08);
    position: relative;
    overflow: hidden;
    animation: fadeIn 0.6s ease-out;
}

.tool-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #1b98e0 0%, #00d4ff 25%, #9b59b6 50%, #e91e63 75%, #1b98e0 100%);
    background-size: 200% 100%;
    animation: neonBorderFlow 4s linear infinite;
}

@keyframes neonBorderFlow {
    0% {
        background-position: 0% 50%;
    }

    100% {
        background-position: 200% 50%;
    }
}

[data-theme="light"] .tool-card {
    background: linear-gradient(165deg, rgba(255, 255, 255, 0.98) 0%, rgba(248, 250, 252, 0.99) 100%);
    border-color: rgba(0, 102, 204, 0.15);
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.12);
}

.tool-header {
    text-align: center;
    margin-bottom: 40px;
}

.tool-title {
    font-size: 2.5rem;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
}

.tool-icon {
    font-size: 2rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.tool-header p {
    color: var(--text-muted);
    font-size: 1.1rem;
}

/* Calculator Input Groups */
.calc-input-group {
    margin-bottom: 20px;
}

.calc-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 10px;
}

.calc-label i {
    color: var(--primary-blue);
}

.calc-input-wrapper {
    display: flex;
    align-items: center;
    background: var(--bg-tertiary);
    border: 2px solid var(--border-color);
    border-radius: 14px;
    overflow: hidden;
    transition: border-color 0.3s;
}

.calc-input-wrapper:focus-within {
    border-color: var(--primary-blue);
    box-shadow: 0 0 20px rgba(27, 152, 224, 0.15);
}

.calc-input-wrapper .input-prefix,
.calc-input-wrapper .input-suffix {
    padding: 16px;
    background: rgba(27, 152, 224, 0.08);
    color: var(--primary-blue);
    font-weight: 600;
    font-family: 'Fira Code', monospace;
    white-space: nowrap;
}

.calc-input {
    flex: 1;
    padding: 16px 20px;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-size: 1rem;
    font-family: 'Poppins', sans-serif;
    outline: none;
}

.calc-input::placeholder {
    color: var(--text-muted);
}

/* Tenure Row */
.tenure-row {
    display: flex;
    gap: 12px;
    align-items: stretch;
}

.tenure-input {
    flex: 1;
}

.tenure-toggle {
    display: flex;
    border: 2px solid var(--border-color);
    border-radius: 14px;
    overflow: hidden;
}

.tenure-btn {
    padding: 16px 20px;
    background: var(--bg-tertiary);
    border: none;
    color: var(--text-muted);
    font-weight: 600;
    font-family: 'Poppins', sans-serif;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 0.9rem;
}

.tenure-btn.active {
    background: var(--primary-blue);
    color: #fff;
}

.tenure-btn:hover:not(.active) {
    color: var(--primary-blue);
}

/* GST Rate Grid & Button Styling */
.gst-rate-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr) 1.2fr;
    gap: 10px;
    margin-top: 8px;
}

.gst-rate-btn {
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    padding: 12px 16px;
    border-radius: 12px;
    font-family: 'Poppins', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.gst-rate-btn:hover {
    border-color: var(--primary-blue);
    color: var(--primary-blue);
    background: rgba(27, 152, 224, 0.1);
}

.gst-rate-btn.active {
    background: var(--gradient-primary);
    border-color: transparent;
    color: #ffffff;
    box-shadow: 0 4px 15px rgba(27, 152, 224, 0.3);
}

.custom-rate-wrap {
    position: relative;
}

.custom-rate-input {
    width: 100%;
    text-align: center;
    padding: 12px;
}

@media (max-width: 600px) {
    .gst-rate-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .custom-rate-wrap {
        grid-column: span 2;
    }
}

/* Result Display — Premium Glow */
.result-display {
    text-align: center;
    padding: 45px 40px;
    background: linear-gradient(145deg, rgba(27, 152, 224, 0.08) 0%, rgba(155, 89, 182, 0.06) 50%, rgba(27, 152, 224, 0.04) 100%);
    border: 1px solid rgba(27, 152, 224, 0.25);
    border-radius: 24px;
    margin: 30px 0;
    position: relative;
    overflow: hidden;
    animation: resultSlideIn 0.5s ease-out;
    box-shadow: 0 10px 40px rgba(27, 152, 224, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.result-display::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, #1b98e0, #9b59b6, #1b98e0, transparent);
    opacity: 0.8;
}

.result-display::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(ellipse at center, rgba(27, 152, 224, 0.06) 0%, transparent 60%);
    pointer-events: none;
    animation: resultGlow 4s ease-in-out infinite;
}

@keyframes resultSlideIn {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.98);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes resultGlow {

    0%,
    100% {
        opacity: 0.5;
        transform: scale(1);
    }

    50% {
        opacity: 1;
        transform: scale(1.05);
    }
}

[data-theme="light"] .result-display {
    background: linear-gradient(145deg, rgba(0, 102, 204, 0.06) 0%, rgba(155, 89, 182, 0.04) 50%, rgba(0, 102, 204, 0.02) 100%);
    border-color: rgba(0, 102, 204, 0.2);
    box-shadow: 0 10px 40px rgba(0, 102, 204, 0.06);
}

.result-label {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 3px;
    font-weight: 600;
    position: relative;
    z-index: 1;
}

.result-value {
    font-size: 3.2rem;
    font-weight: 800;
    font-family: 'Fira Code', monospace;
    background: linear-gradient(135deg, #1b98e0 0%, #00d4ff 40%, #9b59b6 70%, #e91e63 100%);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    line-height: 1.2;
    position: relative;
    z-index: 1;
    animation: gradientShift 3s ease infinite;
    filter: drop-shadow(0 2px 10px rgba(27, 152, 224, 0.3));
}

@keyframes gradientShift {

    0%,
    100% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }
}

/* Result Breakdown — Neon Cards */
.result-breakdown {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin: 25px 0;
}

.breakdown-item {
    padding: 22px 20px;
    background: linear-gradient(145deg, var(--bg-tertiary) 0%, rgba(27, 152, 224, 0.03) 100%);
    border: 1px solid var(--border-color);
    border-radius: 18px;
    text-align: center;
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    animation: breakdownFadeIn 0.5s ease-out backwards;
}

.breakdown-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(to bottom, #1b98e0, #9b59b6);
    border-radius: 4px 0 0 4px;
    opacity: 0.7;
    transition: opacity 0.3s, width 0.3s;
}

.breakdown-item:nth-child(2)::before {
    background: linear-gradient(to bottom, #32de84, #1b98e0);
}

.breakdown-item:nth-child(3)::before {
    background: linear-gradient(to bottom, #9b59b6, #e91e63);
}

.breakdown-item:nth-child(4)::before {
    background: linear-gradient(to bottom, #f39c12, #e74c3c);
}

.breakdown-item:hover {
    border-color: rgba(27, 152, 224, 0.4);
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(27, 152, 224, 0.12);
}

.breakdown-item:hover::before {
    width: 5px;
    opacity: 1;
}

@keyframes breakdownFadeIn {
    from {
        opacity: 0;
        transform: translateY(15px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.breakdown-item:nth-child(1) {
    animation-delay: 0.1s;
}

.breakdown-item:nth-child(2) {
    animation-delay: 0.2s;
}

.breakdown-item:nth-child(3) {
    animation-delay: 0.3s;
}

.breakdown-item:nth-child(4) {
    animation-delay: 0.4s;
}

.breakdown-label {
    font-size: 0.82rem;
    color: var(--text-muted);
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 500;
}

.breakdown-value {
    font-size: 1.4rem;
    font-weight: 700;
    font-family: 'Fira Code', monospace;
    color: var(--primary-blue);
    text-shadow: 0 0 20px rgba(27, 152, 224, 0.15);
}

/* Chart Container — Premium Glass */
.chart-container {
    position: relative;
    margin: 30px 0;
    padding: 30px 25px 25px;
    background: linear-gradient(160deg, var(--bg-tertiary) 0%, rgba(27, 152, 224, 0.04) 100%);
    border: 1px solid rgba(27, 152, 224, 0.15);
    border-radius: 24px;
    width: 100%;
    max-height: 420px;
    aspect-ratio: 16 / 9;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.15), inset 0 1px 0 rgba(255, 255, 255, 0.04);
    animation: chartReveal 0.6s ease-out;
    overflow: hidden;
}

.chart-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, #1b98e0 0%, #9b59b6 50%, #32de84 100%);
    opacity: 0.6;
}

.chart-container::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(27, 152, 224, 0.3), transparent);
}

[data-theme="light"] .chart-container {
    background: linear-gradient(160deg, #f8fafc 0%, rgba(0, 102, 204, 0.03) 100%);
    border-color: rgba(0, 102, 204, 0.12);
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.06);
}

@keyframes chartReveal {
    from {
        opacity: 0;
        transform: scale(0.96);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.chart-container canvas {
    width: 100% !important;
    max-height: 350px;
    position: relative;
    z-index: 1;
}

/* Buttons */
.btn-group {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin: 25px 0;
    flex-wrap: wrap;
}

.btn {
    padding: 14px 28px;
    border-radius: 50px;
    border: 1px solid var(--border-color);
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-family: 'Poppins', sans-serif;
}

.btn:hover {
    transform: translateY(-3px);
}

.btn-primary {
    background: var(--gradient-primary);
    border: none;
    color: #fff;
    box-shadow: 0 10px 30px rgba(27, 152, 224, 0.4);
}

.btn-primary:hover {
    box-shadow: 0 15px 40px rgba(27, 152, 224, 0.6);
}

.btn-secondary:hover {
    border-color: var(--primary-blue);
    color: var(--primary-blue);
}

.btn-share {
    background: linear-gradient(135deg, #25D366, #128C7E);
    border: none;
    color: #fff;
}

.btn-share:hover {
    box-shadow: 0 10px 30px rgba(37, 211, 102, 0.4);
}

/* Stats Grid — Premium Dashboard */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-top: 30px;
}

.stat-box {
    background: linear-gradient(145deg, rgba(27, 152, 224, 0.1) 0%, rgba(27, 152, 224, 0.02) 100%);
    border: 1px solid rgba(27, 152, 224, 0.18);
    border-radius: 20px;
    padding: 24px 16px;
    text-align: center;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    animation: statPopIn 0.4s ease-out backwards;
}

.stat-box::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 3px;
    border-radius: 3px 3px 0 0;
    background: linear-gradient(90deg, #1b98e0, #9b59b6);
    opacity: 0.5;
    transition: width 0.3s, opacity 0.3s;
}

.stat-box:nth-child(1) {
    animation-delay: 0.1s;
}

.stat-box:nth-child(2) {
    animation-delay: 0.2s;
}

.stat-box:nth-child(3) {
    animation-delay: 0.3s;
}

.stat-box:nth-child(4) {
    animation-delay: 0.4s;
}

.stat-box:nth-child(2)::after {
    background: linear-gradient(90deg, #32de84, #1b98e0);
}

.stat-box:nth-child(3)::after {
    background: linear-gradient(90deg, #9b59b6, #e91e63);
}

.stat-box:nth-child(4)::after {
    background: linear-gradient(90deg, #f39c12, #e74c3c);
}

.stat-box:hover {
    border-color: rgba(27, 152, 224, 0.45);
    transform: translateY(-6px);
    box-shadow: 0 15px 40px rgba(27, 152, 224, 0.12);
}

.stat-box:hover::after {
    width: 70%;
    opacity: 1;
}

@keyframes statPopIn {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.95);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.stat-label {
    font-size: 0.72rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-weight: 500;
}

.stat-value {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--primary-blue);
    font-family: 'Fira Code', monospace;
    margin-top: 8px;
    text-shadow: 0 0 15px rgba(27, 152, 224, 0.15);
}

/* Tips */
.tips-section {
    margin-top: 30px;
    padding: 25px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 16px;
}

.tips-section h3 {
    font-size: 1.1rem;
    color: var(--text-primary);
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.tips-section h3 i {
    color: var(--secondary-green);
}

.tips-grid {
    display: grid;
    gap: 12px;
}

.tip-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 15px;
    background: rgba(50, 222, 132, 0.05);
    border: 1px solid rgba(50, 222, 132, 0.2);
    border-radius: 10px;
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.tip-item i {
    color: var(--secondary-green);
}

/* Bookmark */
.bookmark-section {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.bookmark-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 50px;
    color: var(--text-secondary);
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
}

.bookmark-btn:hover {
    background: var(--primary-blue);
    border-color: var(--primary-blue);
    color: #fff;
    transform: translateY(-2px);
}

/* Ad Slots */
.ad-below-tool {
    max-width: 600px;
    margin: 40px auto;
    padding: 20px;
    background: rgba(27, 152, 224, 0.03);
    border: 1px dashed rgba(27, 152, 224, 0.2);
    border-radius: 16px;
    text-align: center;
    min-height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ad-footer-section {
    max-width: 728px;
    margin: 50px auto 30px;
    padding: 20px;
    background: rgba(27, 152, 224, 0.03);
    border: 1px dashed rgba(27, 152, 224, 0.2);
    border-radius: 16px;
    text-align: center;
    min-height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ad-placeholder-minimal {
    color: var(--text-muted);
    font-size: 0.85rem;
    opacity: 0.6;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Similar Tools */
.similar-tools {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 30px;
    margin-bottom: 30px;
}

.similar-tools h3 {
    font-size: 1.2rem;
    color: var(--text-primary);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.similar-tools h3 i {
    color: var(--primary-blue);
}

.similar-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 15px;
}

.similar-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 20px 15px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    text-decoration: none;
    color: var(--text-secondary);
    transition: all 0.3s;
    text-align: center;
}

.similar-card:hover {
    border-color: var(--primary-blue);
    transform: translateY(-5px);
    color: var(--primary-blue);
}

.similar-card i {
    font-size: 1.8rem;
    color: var(--primary-blue);
}

.similar-card span {
    font-weight: 600;
    font-size: 0.9rem;
}

/* SEO Content */
.seo-content {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 40px;
}

.seo-content h2 {
    font-size: 1.8rem;
    color: var(--text-primary);
    margin: 40px 0 20px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.seo-content h2:first-of-type {
    margin-top: 0;
}

.seo-content h2 i {
    color: var(--primary-blue);
}

.seo-content p {
    margin-bottom: 20px;
}

.seo-content ul,
.seo-content ol {
    margin: 20px 0;
    padding-left: 20px;
}

.seo-content li {
    margin-bottom: 15px;
}

.seo-content strong {
    color: var(--primary-blue);
}

.seo-content a {
    color: var(--primary-blue);
    text-decoration: none;
}

.seo-content a:hover {
    text-decoration: underline;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    list-style: none;
    padding: 0;
    margin: 25px 0;
}

.features-grid li {
    background: var(--bg-tertiary);
    padding: 20px;
    border-radius: 12px;
    border: 1px solid var(--border-color);
}

.features-grid li:hover {
    border-color: var(--primary-blue);
}

.faq-section {
    margin-top: 30px;
}

.faq-item {
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 15px;
}

.faq-item:hover {
    border-color: var(--primary-blue);
}

.faq-item h3 {
    color: var(--text-primary);
    font-size: 1.1rem;
    margin-bottom: 10px;
}

.faq-item p {
    margin: 0;
    color: var(--text-secondary);
}

.cta-box {
    background: var(--gradient-primary);
    padding: 40px;
    border-radius: 16px;
    text-align: center;
    margin: 40px 0;
}

.cta-box h3,
.cta-box p {
    color: #fff;
}

.cta-box h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
}

/* Ultra Footer */
.ultra-footer {
    background: linear-gradient(to top, #050510, #0a0a18);
    position: relative;
    overflow: hidden;
    padding: 80px 0 30px;
    margin-top: 60px;
    border-top: 1px solid rgba(27, 152, 224, 0.2);
}

.footer-grid-pattern {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: radial-gradient(rgba(27, 152, 224, 0.1) 1px, transparent 1px);
    background-size: 50px 50px;
    opacity: 0.5;
    pointer-events: none;
}

.footer-glow-orb {
    position: absolute;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(27, 152, 224, 0.15) 0%, transparent 70%);
    border-radius: 50%;
    top: -150px;
    right: -100px;
    pointer-events: none;
}

.footer-wrapper {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: 40px;
    position: relative;
    z-index: 1;
}

.footer-col {
    display: flex;
    flex-direction: column;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 15px;
    text-decoration: none;
    margin-bottom: 20px;
}

.brand-logo-glow img {
    width: 55px;
    height: 55px;
    border-radius: 50%;
    box-shadow: 0 0 20px rgba(27, 152, 224, 0.5);
}

.brand-name {
    font-size: 1.6rem;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.brand-desc {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.7;
    margin-bottom: 20px;
}

.trust-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 18px;
    background: rgba(27, 152, 224, 0.1);
    border: 1px solid rgba(27, 152, 224, 0.3);
    border-radius: 50px;
    color: var(--primary-blue);
    font-size: 0.85rem;
    font-weight: 500;
}

.col-title {
    font-size: 1rem;
    color: var(--text-primary);
    margin-bottom: 25px;
    padding-bottom: 12px;
    border-bottom: 2px solid rgba(27, 152, 224, 0.3);
}

.link-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.link-list li {
    margin-bottom: 14px;
}

.link-list a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.95rem;
    transition: all 0.3s;
}

.link-list a:hover {
    color: var(--primary-blue);
    transform: translateX(5px);
}

.connect-stack {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.connect-card {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    border-radius: 12px;
    text-decoration: none;
    transition: all 0.3s;
}

.card-yt {
    background: rgba(255, 0, 0, 0.1);
    border: 1px solid rgba(255, 0, 0, 0.3);
}

.card-yt:hover {
    background: rgba(255, 0, 0, 0.2);
    transform: translateY(-3px);
}

.card-yt .card-icon {
    color: #ff0000;
    font-size: 1.5rem;
}

.card-mail {
    background: rgba(27, 152, 224, 0.1);
    border: 1px solid rgba(27, 152, 224, 0.3);
}

.card-mail:hover {
    background: rgba(27, 152, 224, 0.2);
    transform: translateY(-3px);
}

.card-mail .card-icon {
    color: var(--primary-blue);
    font-size: 1.5rem;
}

.card-content {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.card-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.card-value {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
}

.card-arrow {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.social-row {
    display: flex;
    gap: 12px;
    margin-top: 20px;
}

.s-btn {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: all 0.3s;
    font-size: 1rem;
}

.s-btn.fb {
    background: rgba(24, 119, 242, 0.1);
    color: #1877f2;
    border: 1px solid rgba(24, 119, 242, 0.3);
}

.s-btn.insta {
    background: rgba(225, 48, 108, 0.1);
    color: #e1306c;
    border: 1px solid rgba(225, 48, 108, 0.3);
}

.s-btn.x {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-secondary);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.s-btn.tg {
    background: rgba(0, 136, 204, 0.1);
    color: #0088cc;
    border: 1px solid rgba(0, 136, 204, 0.3);
}

.s-btn:hover {
    transform: translateY(-3px) scale(1.1);
}

.footer-copyright {
    text-align: center;
    padding-top: 40px;
    margin-top: 50px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    position: relative;
    z-index: 1;
}

.footer-copyright p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin: 5px 0;
}

.made-with .pulse {
    color: #e74c3c;
    animation: heartbeat 1.5s infinite;
}

@keyframes heartbeat {

    0%,
    100% {
        transform: scale(1);
    }

    15% {
        transform: scale(1.1);
    }

    30% {
        transform: scale(1);
    }
}

/* Chatbot */
#chatbot-toggle {
    position: fixed;
    bottom: 100px;
    right: 25px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--gradient-primary);
    border: none;
    color: #fff;
    font-size: 1.3rem;
    cursor: pointer;
    z-index: 9998;
    box-shadow: 0 5px 20px rgba(27, 152, 224, 0.4);
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
}

#chatbot-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 8px 30px rgba(27, 152, 224, 0.6);
}

#chatbot-container {
    position: fixed;
    bottom: 160px;
    right: 25px;
    width: 350px;
    max-height: 450px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    box-shadow: var(--shadow-lg);
    z-index: 9998;
    display: none;
    flex-direction: column;
    overflow: hidden;
}

#chatbot-container.visible {
    display: flex;
}

.chatbot-header {
    background: var(--gradient-primary);
    color: #fff;
    padding: 15px 20px;
    font-weight: 600;
    font-size: 0.95rem;
}

.chatbot-messages {
    flex: 1;
    padding: 15px;
    overflow-y: auto;
    max-height: 300px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.chat-message {
    padding: 10px 15px;
    border-radius: 12px;
    font-size: 0.9rem;
    max-width: 85%;
    line-height: 1.5;
}

.chat-message.bot {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    align-self: flex-start;
    border-bottom-left-radius: 4px;
}

.chat-message.user {
    background: var(--primary-blue);
    color: #fff;
    align-self: flex-end;
    border-bottom-right-radius: 4px;
}

.chatbot-input-form {
    display: flex;
    padding: 12px;
    border-top: 1px solid var(--border-color);
    gap: 8px;
}

.chatbot-input-form input {
    flex: 1;
    padding: 10px 15px;
    border-radius: 50px;
    border: 1px solid var(--border-color);
    background: var(--bg-tertiary);
    color: var(--text-primary);
    font-family: 'Poppins', sans-serif;
    font-size: 0.9rem;
    outline: none;
}

.chatbot-input-form input:focus {
    border-color: var(--primary-blue);
}

.chatbot-input-form button {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--gradient-primary);
    border: none;
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s;
}

.chatbot-input-form button:hover {
    transform: scale(1.1);
}

/* Responsive */
@media (max-width: 992px) {
    .tool-layout {
        grid-template-columns: 1fr;
    }

    .sidebar {
        position: static;
        order: 2;
    }

    .u-nav-list {
        display: none;
    }

    .footer-wrapper {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .tool-card {
        padding: 25px 20px;
        border-radius: 24px;
    }

    .tool-title {
        font-size: 1.8rem;
    }

    .result-value {
        font-size: 2rem;
    }

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

    .seo-content {
        padding: 25px;
    }

    .seo-content h2 {
        font-size: 1.4rem;
    }

    .tenure-row {
        flex-direction: column;
    }

    .tenure-toggle {
        width: 100%;
    }

    .tenure-btn {
        flex: 1;
        text-align: center;
    }

    #chatbot-toggle {
        bottom: 140px;
        right: 15px;
        width: 45px;
        height: 45px;
    }

    #chatbot-container {
        bottom: 200px;
        right: 10px;
        left: 10px;
        width: auto;
        max-width: none;
        height: 50vh;
        max-height: 350px;
    }
}

@media (max-width: 576px) {
    .footer-wrapper {
        grid-template-columns: 1fr;
    }

    .btn-group {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 100%;
        justify-content: center;
    }

    .ad-footer-section {
        display: none;
    }
}

@media (max-width: 480px) {
    #chatbot-toggle {
        bottom: 130px;
        right: 12px;
        width: 42px;
        height: 42px;
    }

    #chatbot-container {
        bottom: 185px;
        right: 8px;
        left: 8px;
        height: 45vh;
        max-height: 320px;
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

/* Alignment Utilities */
.tool-header p,
.upload-area p,
.upload-content p {
    text-align: center;
}

/* WhatsApp Share Box */
.whatsapp-share-box {
    margin-top: 20px;
    margin-bottom: 20px;
    padding: 15px;
    background: rgba(37, 211, 102, 0.08);
    border: 1px dashed rgba(37, 211, 102, 0.3);
    border-radius: 12px;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
    animation: pulse-border 2s infinite;
}

.whatsapp-share-box .whatsapp-share-text {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.whatsapp-share-box .btn-whatsapp {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #25d366;
    color: #fff;
    padding: 8px 16px;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    font-size: 0.88rem;
    transition: transform 0.2s, box-shadow 0.2s;
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.2);
}

.whatsapp-share-box .btn-whatsapp:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4);
}

.last-updated-text {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}

/* Chatbot Responsive Styles */
@media (max-width: 768px) {
    #chatbot-toggle {
        display: none;
    }
    header .header-right {
        margin-right: 0;
    }
    body #chatbot-container {
        position: fixed;
        top: 75px;
        bottom: auto;
        right: 15px;
        left: 15px;
        width: auto;
        max-width: none;
        height: 60vh;
        max-height: 400px;
        z-index: 10000;
        box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
    }
}

@media (max-width: 480px) {
    body #chatbot-container {
        top: 68px;
        right: 10px;
        left: 10px;
        height: 55vh;
    }
}

/* ==========================================
   TEXT & DEVELOPER TOOLS (page-specific)
   ========================================== */
.tdt-section { margin-top: 24px; scroll-margin-top: 90px; }
.tdt-title { font-size: 1.35rem; font-weight: 700; color: var(--text-primary); margin-bottom: 6px; display: flex; align-items: center; gap: 10px; }
.tdt-title i { color: var(--primary-blue); }
.tdt-sub { color: var(--text-muted); font-size: 0.92rem; margin-bottom: 16px; }
.tdt-textarea { width: 100%; resize: vertical; min-height: 120px; line-height: 1.6; font-family: 'Poppins', sans-serif; }
.tdt-mono { font-family: 'Fira Code', monospace !important; }
.tdt-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 12px; margin: 16px 0; }
.tdt-stat { background: var(--bg-tertiary); border: 1px solid var(--border-color); border-radius: 12px; padding: 12px; text-align: center; display: flex; flex-direction: column; gap: 4px; }
.tdt-stat-value { font-size: 1.4rem; font-weight: 700; color: var(--primary-blue); }
.tdt-stat-label { font-size: 0.75rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; }
.tdt-chip-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0; }
.tdt-chip { background: var(--bg-tertiary); color: var(--text-primary); border: 1px solid var(--border-color); border-radius: 50px; padding: 8px 14px; font-size: 0.85rem; cursor: pointer; font-family: inherit; transition: all 0.2s; }
.tdt-chip:hover { border-color: var(--primary-blue); color: var(--primary-blue); }
.tdt-output-row { display: flex; gap: 10px; align-items: center; margin-bottom: 12px; }
.tdt-output-row .calc-input { flex: 1; min-width: 0; }
.tdt-icon-btn { padding: 12px 16px !important; flex-shrink: 0; }
.tdt-tag { min-width: 46px; font-weight: 700; font-size: 0.8rem; color: var(--primary-blue); }
.tdt-strength { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; font-size: 0.85rem; color: var(--text-muted); }
.tdt-strength-track { flex: 1; height: 8px; border-radius: 8px; background: var(--bg-tertiary); overflow: hidden; }
.tdt-strength-bar { height: 100%; width: 0; border-radius: 8px; transition: width 0.3s, background 0.3s; }
.tdt-strength-bar.weak { background: #e74c3c; }
.tdt-strength-bar.medium { background: #f39c12; }
.tdt-strength-bar.strong { background: #2ecc71; }
.tdt-strength-bar.very-strong { background: #1b98e0; }
.tdt-range { width: 100%; margin: 8px 0 16px; accent-color: var(--primary-blue); }
.tdt-check-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr)); gap: 10px; color: var(--text-primary); font-size: 0.9rem; margin-bottom: 8px; }
.tdt-check-grid input { accent-color: var(--primary-blue); margin-right: 6px; }
.tdt-inline-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin: 12px 0; }
.tdt-inline-grid .calc-label { display: flex; flex-direction: column; gap: 6px; }
.tdt-color { width: 100%; height: 44px; border: 1px solid var(--border-color); border-radius: 10px; background: transparent; cursor: pointer; padding: 2px; }
.tdt-color-row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-bottom: 14px; }
.tdt-color-big { width: 80px; height: 80px; }
.tdt-color-preview { width: 80px; height: 80px; border-radius: 12px; border: 1px solid var(--border-color); }
.tdt-qr-result { flex-direction: column; align-items: center; gap: 14px; margin-top: 18px; }
.tdt-qr-result canvas { max-width: 100%; height: auto; width: 280px; border-radius: 8px; background: #fff; }
.tdt-status { min-height: 1.2em; margin: 10px 0; font-size: 0.88rem; font-weight: 500; }
.tdt-status.ok { color: #2ecc71; }
.tdt-status.err { color: #e74c3c; }
.tdt-toast { position: fixed; bottom: 100px; left: 50%; transform: translateX(-50%); padding: 12px 24px; border-radius: 50px; color: #fff; font-weight: 500; z-index: 10000; box-shadow: 0 10px 30px rgba(0,0,0,0.3); font-family: 'Poppins', sans-serif; font-size: 0.95rem; background: #2ecc71; max-width: 90vw; text-align: center; }
.tdt-toast.error { background: #e74c3c; }
@media (max-width: 600px) {
    .tdt-title { font-size: 1.15rem; }
    .tdt-output-row .btn { flex: 0 0 auto; width: auto !important; }
    .tdt-output-row .tdt-icon-btn { padding: 10px 14px !important; }
    .tdt-output-row { gap: 6px; }
    .tdt-tag { min-width: 34px; font-size: 0.72rem; }
    .tdt-color-values .calc-input { font-size: 0.8rem !important; padding-left: 8px !important; padding-right: 8px !important; }
}

/* ==========================================
   SEO / GEO blocks (generator pages)
   ========================================== */
.quick-answer { background: rgba(27, 152, 224, 0.08); border: 1px solid rgba(27, 152, 224, 0.35); border-left: 4px solid var(--primary-blue); border-radius: 12px; padding: 18px 20px; margin: 0 0 28px; }
.quick-answer h2 { margin: 0 0 8px !important; font-size: 1.1rem !important; }
.quick-answer p { margin: 0 !important; }
.key-facts { width: 100%; border-collapse: collapse; margin: 16px 0 28px; font-size: 0.95rem; }
.key-facts th, .key-facts td { padding: 12px 14px; border-bottom: 1px solid var(--border-color); text-align: left; vertical-align: top; }
.key-facts th { width: 34%; color: var(--primary-blue); font-weight: 600; background: rgba(27, 152, 224, 0.06); }
.tool-meta { display: flex; align-items: center; justify-content: center; gap: 8px; color: var(--text-muted); font-size: 0.85rem; margin-top: 10px; flex-wrap: wrap; }
.hi-subtitle { color: var(--text-muted); font-size: 0.95rem; margin-top: 4px; }
.hub-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 16px; margin: 20px 0; }
.hub-card { display: flex; flex-direction: column; gap: 8px; padding: 20px; border-radius: 14px; background: var(--bg-tertiary); border: 1px solid var(--border-color); color: var(--text-primary); text-decoration: none; transition: transform .2s, border-color .2s; }
.hub-card:hover { transform: translateY(-3px); border-color: var(--primary-blue); }
.hub-card i { font-size: 1.5rem; color: var(--primary-blue); }
.hub-card strong { font-size: 1.05rem; }
.hub-card span { color: var(--text-muted); font-size: 0.88rem; line-height: 1.5; }
html[data-theme="light"] .key-facts th { background: rgba(0, 102, 204, 0.06); }

/* ---- Image tools (shared by generated image tools) ---- */
.it-upload { border: 3px dashed var(--border-color); border-radius: 24px; padding: 48px 32px; text-align: center; cursor: pointer; transition: all 0.3s ease; background: rgba(27, 152, 224, 0.03); display: block; }
.it-upload:hover, .it-upload:focus-visible { border-color: var(--primary-blue); background: rgba(27, 152, 224, 0.08); outline: none; }
.it-upload.dragover { border-color: var(--secondary-green); background: rgba(50, 222, 132, 0.1); }
.it-upload i { font-size: 3.2rem; color: var(--primary-blue); margin-bottom: 14px; display: block; }
.it-upload strong { display: block; font-size: 1.2rem; color: var(--text-primary); margin-bottom: 6px; }
.it-upload span { display: block; color: var(--text-muted); font-size: 0.95rem; }
.it-upload .it-hint { display: inline-block; margin-top: 12px; font-size: 0.82rem; background: var(--bg-tertiary); padding: 6px 14px; border-radius: 20px; }
.it-upload input[type="file"] { display: none; }
.it-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 14px; }
.it-chip { background: var(--bg-tertiary); border: 1px solid var(--border-color); color: var(--text-primary); padding: 8px 14px; border-radius: 20px; font-family: 'Poppins', sans-serif; font-size: 0.88rem; font-weight: 600; cursor: pointer; transition: all 0.2s ease; }
.it-chip:hover { border-color: var(--primary-blue); color: var(--primary-blue); }
.it-chip.active { background: var(--primary-blue); border-color: var(--primary-blue); color: #fff; }
.it-chip.active { background: var(--gradient-primary); color: #fff; border-color: transparent; }
.it-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 14px; }
.it-select { width: 100%; }
.it-preview { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 22px 0; }
.it-preview figure { margin: 0; background: var(--bg-tertiary); border: 1px solid var(--border-color); border-radius: 16px; padding: 14px; text-align: center; }
.it-preview figcaption { font-size: 0.9rem; font-weight: 600; color: var(--text-primary); margin-bottom: 10px; }
.it-preview figcaption small { display: block; font-weight: 400; color: var(--text-muted); margin-top: 2px; }
.it-preview .it-img-wrap { min-height: 160px; display: flex; align-items: center; justify-content: center; background: repeating-conic-gradient(rgba(128,128,128,0.15) 0% 25%, transparent 0% 50%) 50% / 20px 20px; border-radius: 10px; overflow: hidden; }
.it-preview img { max-width: 100%; max-height: 280px; width: auto; height: auto; object-fit: contain; display: block; }
.it-note { font-size: 0.9rem; color: var(--text-muted); background: rgba(27, 152, 224, 0.06); border-left: 3px solid var(--primary-blue); padding: 10px 14px; border-radius: 8px; margin: 12px 0; }
.it-note.warn { border-left-color: #f39c12; background: rgba(243, 156, 18, 0.08); }
.it-progress { color: var(--primary-blue); font-weight: 600; font-size: 0.92rem; margin: 10px 0; min-height: 1.4em; }
.it-hidden { display: none !important; }
@media (max-width: 600px) {
    .it-upload { padding: 34px 18px; }
    .it-preview { grid-template-columns: 1fr; }
}
.it-list { display: flex; flex-direction: column; gap: 10px; margin: 18px 0; }
.it-item { display: grid; grid-template-columns: 56px 1fr auto; gap: 12px; align-items: center; background: var(--bg-tertiary); border: 1px solid var(--border-color); border-radius: 14px; padding: 10px 12px; }
.it-item img, .it-item .it-thumb { width: 56px; height: 56px; object-fit: cover; border-radius: 8px; background: repeating-conic-gradient(rgba(128,128,128,0.18) 0% 25%, transparent 0% 50%) 50% / 12px 12px; display: flex; align-items: center; justify-content: center; color: var(--text-muted); }
.it-item .it-name { color: var(--text-primary); font-weight: 600; font-size: 0.92rem; word-break: break-all; }
.it-item .it-meta { color: var(--text-muted); font-size: 0.82rem; margin-top: 2px; }
.it-item .it-meta.err { color: #e74c3c; }
.it-item .btn { padding: 9px 14px !important; font-size: 0.85rem; }
@media (max-width: 480px) { .it-item { grid-template-columns: 44px 1fr; } .it-item img, .it-item .it-thumb { width: 44px; height: 44px; } .it-item .btn { grid-column: 1 / -1; } }

/* ---- Article tables (generated pages) ---- */
.seo-table-wrapper { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 20px 0; max-width: 100%; }
.seo-table { width: 100%; border-collapse: collapse; margin-bottom: 8px; font-size: 0.95rem; text-align: left; }
.seo-table th, .seo-table td { padding: 12px 16px; border-bottom: 1px solid var(--border-color); vertical-align: top; }
.seo-table th { background-color: rgba(27, 152, 224, 0.15); color: var(--primary-blue); font-weight: 600; white-space: nowrap; }
@media (max-width: 600px) { .seo-table { font-size: 0.85rem; } .seo-table th, .seo-table td { padding: 9px 10px; } }
.key-facts th, .key-facts td, .seo-table td { overflow-wrap: anywhere; }
@media (max-width: 600px) { .seo-content table:not(.key-facts) { display: block; overflow-x: auto; max-width: 100%; } }
.seo-content p, .seo-content li, .faq-item h3 { overflow-wrap: anywhere; }

/* ---- Image editors (canvas + side panel), shared ---- */
.pp-editor { display: grid; grid-template-columns: minmax(0, 360px) minmax(0, 1fr); gap: 24px; align-items: start; }
.pp-stage, .tx-stage { background: var(--bg-tertiary); border: 1px solid var(--border-color); border-radius: 16px; padding: 12px; text-align: center; }
.pp-stage canvas, .tx-stage canvas { touch-action: none; cursor: grab; border-radius: 4px; box-shadow: 0 6px 24px rgba(0, 0, 0, 0.25); display: block; margin: 0 auto; max-width: 100%; outline: none; background: repeating-conic-gradient(rgba(128,128,128,0.18) 0% 25%, transparent 0% 50%) 50% / 16px 16px; }
.px-stage canvas { cursor: crosshair; }
.pp-help { color: var(--text-muted); font-size: 0.82rem; margin: 10px 0 6px; }
.pp-settings .btn-group, .tx-panel .btn-group { justify-content: flex-start; }
.tx-editor { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.tx-textarea { width: 100%; min-height: 64px; resize: vertical; font-family: inherit; margin-bottom: 12px; }
.tx-color { width: 100%; height: 46px; border: 1px solid var(--border-color); border-radius: 12px; background: var(--bg-tertiary); padding: 4px; cursor: pointer; }
.ro-preview { grid-template-columns: 1fr; max-width: 560px; margin-left: auto; margin-right: auto; }
.ro-preview canvas { max-width: 100%; height: auto; }
@media (max-width: 860px) { .tx-editor { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 760px) { .pp-editor { grid-template-columns: minmax(0, 1fr); } .pp-settings .btn-group, .tx-panel .btn-group { justify-content: center; } }

/* ---- Video & audio tools (shared) ---- */
.md-info { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 10px; margin: 14px 0; }
.md-info div { background: var(--bg-tertiary); border: 1px solid var(--border-color); border-radius: 12px; padding: 10px 12px; }
.md-info small { display: block; color: var(--text-muted); font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.04em; }
.md-info strong { color: var(--text-primary); font-size: 0.95rem; word-break: break-word; }
.md-player { width: 100%; max-height: 360px; border-radius: 12px; background: #000; display: block; margin: 10px 0; }
audio.md-player { background: transparent; height: 54px; }
.md-bar { height: 10px; border-radius: 6px; background: var(--bg-tertiary); border: 1px solid var(--border-color); overflow: hidden; margin: 12px 0 6px; }
.md-bar > div { height: 100%; width: 0; background: var(--gradient-primary); transition: width 0.2s ease; }
.md-status { color: var(--primary-blue); font-weight: 600; font-size: 0.92rem; min-height: 1.4em; }
.md-result { background: rgba(50, 222, 132, 0.06); border: 1px solid rgba(50, 222, 132, 0.35); border-radius: 16px; padding: 16px; margin: 18px 0; }
.md-result h3 { margin: 0 0 8px; font-size: 1.05rem; color: var(--text-primary); }
.md-wave { width: 100%; height: 140px; display: block; background: var(--bg-tertiary); border: 1px solid var(--border-color); border-radius: 12px; touch-action: none; cursor: pointer; }
.md-range2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 12px; align-items: end; }
.md-big { font-family: 'Fira Code', monospace; font-size: 2.4rem; font-weight: 600; color: var(--text-primary); text-align: center; margin: 10px 0; }
.md-note-warn { border-left-color: #f39c12 !important; background: rgba(243, 156, 18, 0.08) !important; }

/* ---- Calculators (shared, calc-kit.js) ---- */
.ck-chart { display: flex; align-items: center; justify-content: center; gap: 22px; flex-wrap: wrap; margin: 18px 0; }
.ck-chart canvas { width: 200px; height: 200px; }
.ck-legend { display: flex; flex-direction: column; gap: 8px; font-size: 0.9rem; color: var(--text-primary); }
.ck-legend i { display: inline-block; width: 12px; height: 12px; border-radius: 3px; margin-right: 8px; vertical-align: -1px; }
.ck-table-wrap { max-height: 360px; overflow: auto; border: 1px solid var(--border-color); border-radius: 12px; margin: 14px 0; }
.ck-table { margin: 0 !important; font-size: 0.88rem !important; }
.ck-table th { position: sticky; top: 0; background: var(--bg-tertiary) !important; }
.ck-steps { background: var(--bg-tertiary); border: 1px solid var(--border-color); border-radius: 12px; padding: 14px 16px; font-family: 'Fira Code', monospace; font-size: 0.9rem; color: var(--text-primary); white-space: pre-wrap; line-height: 1.7; margin: 12px 0; overflow-x: auto; }
.ck-tabs { margin-bottom: 16px; flex-wrap: wrap; }
.ck-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; align-items: end; }
.ck-list-row { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) minmax(0, 1fr) auto; gap: 8px; align-items: center; margin-bottom: 8px; }
.ck-list-row .calc-input { padding: 10px 12px; }
.ck-list-row .calc-input, .fr-row .calc-input { width: 100%; min-width: 0; background: var(--bg-tertiary); border: 2px solid var(--border-color); border-radius: 12px; transition: border-color 0.2s; }
.ck-list-row .calc-input:focus, .fr-row .calc-input:focus { border-color: var(--primary-blue); }
.ck-list-row select.calc-input option, .fr-row select.calc-input option { background: var(--bg-secondary); color: var(--text-primary); }
.ck-x { background: transparent; border: 1px solid var(--border-color); color: var(--text-muted); border-radius: 10px; width: 40px; height: 40px; cursor: pointer; }
.ck-x:hover { color: #e74c3c; border-color: #e74c3c; }
.ck-badge { display: inline-block; padding: 4px 12px; border-radius: 20px; font-weight: 700; font-size: 0.9rem; color: #fff; background: var(--primary-blue); margin-top: 8px; }
.ck-list-head { font-size: 0.8rem; color: var(--text-muted); font-weight: 600; margin-bottom: 4px; }
.ck-grid-out { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 10px; margin: 12px 0; }
.ck-grid-out div { background: var(--bg-tertiary); border: 1px solid var(--border-color); border-radius: 12px; padding: 10px 12px; color: var(--text-primary); font-size: 0.9rem; overflow-wrap: anywhere; }
.ck-grid-out b { display: block; color: var(--text-muted); font-size: 0.78rem; font-weight: 600; margin-bottom: 2px; }
@media (max-width: 600px) { .ck-list-head { display: none; } .ck-list-row { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } .ck-list-row .ck-x { grid-column: 2; justify-self: end; } }

/* ---- dev tools shared ---- */
.cm-code { font-family: 'Fira Code', monospace !important; font-size: 0.86rem !important; line-height: 1.6; }
.kv-list { display: flex; flex-direction: column; gap: 8px; margin: 12px 0; }
.kv-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; background: var(--bg-tertiary); border: 1px solid var(--border-color); border-radius: 12px; padding: 10px 14px; }
.kv-row > div { min-width: 0; }
.kv-row b { display: block; font-size: 0.78rem; color: var(--text-muted); }
.kv-row code { display: block; font-family: 'Fira Code', monospace; font-size: 0.88rem; color: var(--text-primary); overflow-wrap: anywhere; }
.kv-row .ck-x { flex-shrink: 0; }

/* ---- utility tools shared ---- */
.rn-hist { margin: 6px 0 4px 22px; line-height: 1.8; color: var(--text-secondary, var(--text-muted)); font-size: 0.92rem; max-height: 260px; overflow-y: auto; overflow-wrap: anywhere; }
.rn-hist:empty::before { content: 'Nothing yet.'; opacity: 0.7; }
.rn-pop { animation: rnPop 0.35s ease; }
@keyframes rnPop { 0% { transform: scale(0.85); opacity: 0.4; } 60% { transform: scale(1.06); } 100% { transform: scale(1); opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .rn-pop { animation: none; } }


/* ---- countdown-timer ---- */
.ct-hms { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.ct-hms .calc-input { text-align: center; font-size: 1.3rem; font-family: 'Fira Code', monospace; }
.ct-face { position: relative; width: min(320px, 100%); aspect-ratio: 1; margin: 16px auto; }
.ct-face:fullscreen { width: 100vw; height: 100vh; margin: 0; background: var(--bg-primary, #0f172a); display: flex; align-items: center; justify-content: center; }
.ct-face:fullscreen .ct-ring { width: min(90vw, 90vh); height: min(90vw, 90vh); position: relative; }
.ct-face:fullscreen .ct-time { font-size: 12vmin; }
.ct-ring { width: 100%; height: 100%; transform: rotate(-90deg); }
.ct-track { fill: none; stroke: var(--border-color); stroke-width: 8; }
.ct-prog { fill: none; stroke: var(--primary-blue); stroke-width: 8; stroke-linecap: round; transition: stroke-dashoffset 0.25s linear; }
.ct-center { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 0 12%; }
.ct-label { color: var(--text-muted); font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.1em; overflow-wrap: anywhere; }
.ct-time { font-family: 'Fira Code', monospace; font-size: clamp(2rem, 11vw, 3.4rem); font-weight: 700; color: var(--text-primary); font-variant-numeric: tabular-nums; line-height: 1.15; }
.ct-end { color: var(--text-muted); font-size: 0.82rem; }
.ct-done .ct-prog { stroke: #dc2626; }
.ct-done .ct-time { color: #dc2626; animation: ctBlink 1s steps(2) infinite; }
@keyframes ctBlink { 50% { opacity: 0.35; } }
.ct-alarm { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; font-weight: 700; font-size: 1.05rem; }
@media (prefers-reduced-motion: reduce) { .ct-done .ct-time { animation: none; } }
