/* ============================================================
   TextCraft — Premium Design System
   ============================================================ */

/* ---------- Design Tokens ---------- */
:root {
    --primary: #FF7A00;
    --primary-dark: #E56D00;
    --primary-light: #FFA042;
    --accent: #FF9F43;
    --bg: #FFFFFF;
    --bg-soft: #F7F8FA;
    --bg-section: #FAFBFC;
    --text: #2D3748;
    --text-light: #718096;
    --text-muted: #A0AEC0;
    --border: #E2E8F0;
    --border-light: #EDF2F7;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 4px 14px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.1);
    --shadow-card: 0 2px 12px rgba(0, 0, 0, 0.06);
    --shadow-hover: 0 12px 36px rgba(0, 0, 0, 0.12);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);

    /* Tool-specific accent colors (iLovePDF-style) */
    --tool-word: #FF7A00;
    --tool-char: #2B6CB0;
    --tool-case: #38A169;
    --tool-line: #D69E2E;
    --tool-format: #805AD5;
}

/* ---------- Reset & Base ---------- */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background-color: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'Space Grotesk', 'Plus Jakarta Sans', sans-serif;
}

/* ---------- Animations ---------- */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.85);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-12px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-8px);
    }
}

@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }

    100% {
        background-position: 200% 0;
    }
}

@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

@keyframes popIn {
    0% {
        opacity: 0;
        transform: scale(0.5);
    }

    70% {
        transform: scale(1.08);
    }

    100% {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(60px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }
}

/* Scroll-triggered animation classes */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

.animate-on-scroll.from-left {
    transform: translateX(-30px);
}

.animate-on-scroll.from-left.visible {
    transform: translateX(0);
}

.animate-on-scroll.from-right {
    transform: translateX(30px);
}

.animate-on-scroll.from-right.visible {
    transform: translateX(0);
}

.animate-on-scroll.scale-up {
    transform: scale(0.9);
}

.animate-on-scroll.scale-up.visible {
    transform: scale(1);
}

/* Stagger delays for children */
.stagger-children>*:nth-child(1) {
    transition-delay: 0.05s;
}

.stagger-children>*:nth-child(2) {
    transition-delay: 0.10s;
}

.stagger-children>*:nth-child(3) {
    transition-delay: 0.15s;
}

.stagger-children>*:nth-child(4) {
    transition-delay: 0.20s;
}

.stagger-children>*:nth-child(5) {
    transition-delay: 0.25s;
}

.stagger-children>*:nth-child(6) {
    transition-delay: 0.30s;
}

/* Button ripple effect */
button::after,
.btn::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.3) 10%, transparent 70%);
    opacity: 0;
    transform: scale(0);
    transition: opacity 0.4s, transform 0.4s;
}

button:active::after,
.btn:active::after {
    opacity: 1;
    transform: scale(2.5);
    transition: 0s;
}

/* Floating icon animation (for hero badges & tool icons) */
.float-anim {
    animation: float 3s ease-in-out infinite;
}

.float-anim:nth-child(2) {
    animation-delay: 0.5s;
}

.float-anim:nth-child(3) {
    animation-delay: 1s;
}

/* ---------- Navigation ---------- */
nav {
    background: var(--bg);
    border-bottom: 1px solid var(--border-light);
    padding: 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: box-shadow var(--transition);
}

nav.scrolled {
    box-shadow: var(--shadow-md);
}

nav .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 68px;
}

nav .logo {
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--primary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    transition: opacity var(--transition);
    flex-shrink: 0;
}

nav .logo:hover {
    opacity: 0.85;
}

nav .logo .logo-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
}

nav .logo .logo-icon svg {
    width: 100%;
    height: 100%;
}

/* Hamburger Toggle */
.nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    z-index: 1001;
    box-shadow: none;
}

.nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text);
    margin: 5px 0;
    border-radius: 2px;
    transition: var(--transition);
}

.nav-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle.active span:nth-child(2) {
    opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* Nav Links */
.nav-links {
    display: flex;
    gap: 0.25rem;
    list-style: none;
    align-items: center;
}

.nav-links a {
    color: var(--text);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.935rem;
    padding: 0.5rem 0.9rem;
    border-radius: var(--radius-sm);
    transition: all var(--transition);
    white-space: nowrap;
    position: relative;
}

.nav-links a:hover {
    color: var(--primary);
    background: rgba(255, 122, 0, 0.06);
}

.nav-links a.active {
    color: var(--primary);
    font-weight: 600;
}

.nav-links a.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0.9rem;
    right: 0.9rem;
    height: 2px;
    background: var(--primary);
    border-radius: 2px;
}

/* ---------- Main Content ---------- */
main {
    flex: 1;
    width: 100%;
    animation: fadeIn 0.6s ease-out;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.container--narrow {
    max-width: 860px;
}

/* ---------- Hero Section ---------- */
.hero {
    text-align: center;
    padding: 4.5rem 2rem 3rem;
    background: linear-gradient(170deg, #FFF 0%, var(--bg-soft) 100%);
    animation: fadeInUp 0.8s ease-out;
}

.hero h1 {
    font-size: 2.75rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 1rem;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

.hero h1 .text-accent {
    color: var(--primary);
}

.hero p {
    font-size: 1.15rem;
    color: var(--text-light);
    max-width: 640px;
    margin: 0 auto 2rem;
    line-height: 1.7;
}

.hero-badges {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 2rem;
    flex-wrap: wrap;
}

.hero-badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: var(--text-light);
    font-weight: 500;
}

.hero-badge .badge-icon {
    font-size: 1.2rem;
}

/* ---------- Tool Cards Grid ---------- */
.tools-section {
    padding: 3rem 0 4rem;
}

.tools-section .section-title {
    text-align: center;
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 2.5rem;
}

.tool-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    max-width: 1000px;
    margin: 0 auto;
}

.tool-card {
    background: var(--bg);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 2rem 1.5rem;
    text-decoration: none;
    color: var(--text);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 0.75rem;
    cursor: pointer;
    transition: all var(--transition);
    box-shadow: var(--shadow-card);
    animation: fadeInUp 0.6s ease-out both;
    position: relative;
    overflow: hidden;
}

.tool-card:nth-child(1) {
    animation-delay: 0.05s;
}

.tool-card:nth-child(2) {
    animation-delay: 0.10s;
}

.tool-card:nth-child(3) {
    animation-delay: 0.15s;
}

.tool-card:nth-child(4) {
    animation-delay: 0.20s;
}

.tool-card:nth-child(5) {
    animation-delay: 0.25s;
}

.tool-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--card-accent, var(--primary));
    opacity: 0;
    transition: opacity var(--transition);
}

.tool-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-hover);
    border-color: transparent;
}

.tool-card:hover::before {
    opacity: 1;
}

.tool-card-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    flex-shrink: 0;
    transition: transform var(--transition);
}

.tool-card:hover .tool-card-icon {
    transform: scale(1.1);
}

/* Card accent colors */
.tool-card--word {
    --card-accent: var(--tool-word);
}

.tool-card--char {
    --card-accent: var(--tool-char);
}

.tool-card--case {
    --card-accent: var(--tool-case);
}

.tool-card--line {
    --card-accent: var(--tool-line);
}

.tool-card--format {
    --card-accent: var(--tool-format);
}

.tool-card--word .tool-card-icon {
    background: rgba(255, 122, 0, 0.1);
    color: var(--tool-word);
}

.tool-card--char .tool-card-icon {
    background: rgba(43, 108, 176, 0.1);
    color: var(--tool-char);
}

.tool-card--case .tool-card-icon {
    background: rgba(56, 161, 105, 0.1);
    color: var(--tool-case);
}

.tool-card--line .tool-card-icon {
    background: rgba(214, 158, 46, 0.1);
    color: var(--tool-line);
}

.tool-card--format .tool-card-icon {
    background: rgba(128, 90, 213, 0.1);
    color: var(--tool-format);
}

.tool-card h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text);
    margin: 0;
}

.tool-card p {
    font-size: 0.875rem;
    color: var(--text-light);
    line-height: 1.55;
    margin: 0;
}

/* ---------- Features Strip ---------- */
.features-section {
    background: var(--bg-soft);
    padding: 3.5rem 0;
    border-top: 1px solid var(--border-light);
    border-bottom: 1px solid var(--border-light);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    max-width: 900px;
    margin: 0 auto;
}

.feature-item {
    text-align: center;
    animation: fadeInUp 0.6s ease-out both;
}

.feature-item:nth-child(1) {
    animation-delay: 0.1s;
}

.feature-item:nth-child(2) {
    animation-delay: 0.2s;
}

.feature-item:nth-child(3) {
    animation-delay: 0.3s;
}

.feature-item:nth-child(4) {
    animation-delay: 0.4s;
}

.feature-item:nth-child(5) {
    animation-delay: 0.5s;
}

.feature-item:nth-child(6) {
    animation-delay: 0.6s;
}

.feature-icon {
    font-size: 2rem;
    margin-bottom: 0.75rem;
}

.feature-item h4 {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 0.35rem;
}

.feature-item p {
    font-size: 0.835rem;
    color: var(--text-light);
    line-height: 1.5;
}

/* ---------- Ad Banner (Non-Intrusive) ---------- */
.ad-section {
    padding: 2.5rem 0;
    display: flex;
    justify-content: center;
}

.ad-banner {
    max-width: 728px;
    width: 100%;
    background: var(--bg-soft);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    padding: 1.25rem 1.5rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.ad-banner::before {
    content: 'Sponsored';
    position: absolute;
    top: 0.5rem;
    right: 0.75rem;
    font-size: 0.65rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.ad-banner-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.25rem;
    flex-wrap: wrap;
}

.ad-banner-text {
    text-align: left;
}

.ad-banner-text h4 {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 0.2rem;
}

.ad-banner-text p {
    font-size: 0.82rem;
    color: var(--text-light);
}

.ad-banner-cta {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: var(--primary);
    color: #fff;
    font-size: 0.82rem;
    font-weight: 600;
    padding: 0.55rem 1.25rem;
    border-radius: 50px;
    text-decoration: none;
    transition: all var(--transition);
    white-space: nowrap;
    border: none;
    cursor: pointer;
    box-shadow: none;
}

.ad-banner-cta:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(255, 122, 0, 0.25);
}

/* ---------- Tool Page Layout ---------- */
.tool-page-header {
    text-align: center;
    padding: 3rem 2rem 1.5rem;
    background: linear-gradient(170deg, #FFF 0%, var(--bg-soft) 100%);
    animation: fadeInUp 0.6s ease-out;
}

.tool-page-header .tool-icon-lg {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    margin-bottom: 1rem;
}

.tool-page-header h1 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 0.5rem;
    letter-spacing: -0.01em;
}

.tool-page-header .tool-desc {
    font-size: 1rem;
    color: var(--text-light);
    max-width: 560px;
    margin: 0 auto;
    line-height: 1.6;
}

/* Tool Section Card */
.tool-section {
    background: var(--bg);
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    box-shadow: var(--shadow-md);
    margin: -1rem auto 2rem;
    max-width: 860px;
    border: 1px solid var(--border-light);
    animation: fadeInUp 0.7s ease-out 0.1s both;
    position: relative;
}

.tool-section h1 {
    color: var(--primary);
    font-size: 1.75rem;
    margin-bottom: 1rem;
    font-weight: 700;
}

.tool-section h2 {
    color: var(--text);
    font-size: 1.05rem;
    font-weight: 600;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.tool-section h2::before {
    content: '';
    width: 3px;
    height: 18px;
    background: var(--primary);
    border-radius: 2px;
    flex-shrink: 0;
}

/* Intro Text */
.intro-text {
    background: var(--bg-soft);
    padding: 1.25rem 1.5rem;
    border-radius: var(--radius-md);
    margin-bottom: 1.5rem;
    font-size: 0.92rem;
    line-height: 1.7;
    color: var(--text-light);
    border-left: 3px solid var(--primary);
}

.intro-text p {
    margin-bottom: 0.75rem;
}

.intro-text p:last-child {
    margin-bottom: 0;
}

.intro-text strong {
    color: var(--text);
}

/* ---------- Textarea ---------- */
textarea {
    width: 100%;
    min-height: 200px;
    padding: 1rem 1.25rem;
    border: 2px solid var(--border);
    border-radius: var(--radius-md);
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    line-height: 1.65;
    color: var(--text);
    resize: vertical;
    transition: all var(--transition);
    background: var(--bg);
}

textarea::placeholder {
    color: var(--text-muted);
}

textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(255, 122, 0, 0.1);
}

textarea.output {
    background: var(--bg-soft);
    border-color: var(--border-light);
}

textarea.output:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(255, 122, 0, 0.08);
}

/* ---------- Buttons ---------- */
.btn-group {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin: 1.25rem 0;
}

button,
.btn {
    background: var(--primary);
    color: #fff;
    border: none;
    padding: 0.7rem 1.5rem;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 600;
    font-family: 'Inter', sans-serif;
    cursor: pointer;
    transition: all var(--transition);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    box-shadow: none;
    position: relative;
    overflow: hidden;
}

button:hover,
.btn:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 122, 0, 0.25);
}

button:active,
.btn:active {
    transform: translateY(0);
    box-shadow: none;
}

button.secondary {
    background: var(--bg-soft);
    color: var(--text);
    border: 1px solid var(--border);
}

button.secondary:hover {
    background: var(--border-light);
    box-shadow: var(--shadow-sm);
    transform: translateY(-1px);
}

/* ---------- Stats Display ---------- */
.stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 0.75rem;
    margin: 1.25rem 0;
}

.stat-box {
    background: var(--bg);
    padding: 1rem;
    border-radius: var(--radius-md);
    text-align: center;
    border: 1px solid var(--border-light);
    transition: all var(--transition);
    position: relative;
    overflow: hidden;
}

.stat-box::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--primary);
    opacity: 0.6;
}

.stat-box:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

.stat-box .label {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-bottom: 0.4rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.stat-box .value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
}

/* ---------- Progress Bar ---------- */
.progress-container {
    margin: 1rem 0;
}

.progress-label {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.4rem;
    font-size: 0.82rem;
    color: var(--text-light);
    font-weight: 500;
}

.progress-bar {
    width: 100%;
    height: 10px;
    background: var(--bg-soft);
    border-radius: 50px;
    overflow: hidden;
    border: 1px solid var(--border-light);
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
    transition: width 0.4s ease, background-color 0.4s ease;
    border-radius: 50px;
}

.progress-fill.warning {
    background: linear-gradient(90deg, #F6AD55, #ED8936);
}

.progress-fill.danger {
    background: linear-gradient(90deg, #FC8181, #E53E3E);
}

/* ---------- Options ---------- */
.options {
    background: var(--bg-soft);
    padding: 1.25rem 1.5rem;
    border-radius: var(--radius-md);
    margin: 1.25rem 0;
    border: 1px solid var(--border-light);
}

.option-group {
    margin-bottom: 0.75rem;
}

.option-group:last-child {
    margin-bottom: 0;
}

.option-group label {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    cursor: pointer;
    font-weight: 500;
    font-size: 0.92rem;
    color: var(--text);
    transition: color var(--transition);
    padding: 0.25rem 0;
}

.option-group label:hover {
    color: var(--primary);
}

.option-group input[type="checkbox"],
.option-group input[type="radio"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: var(--primary);
}

/* ---------- Output Section ---------- */
.output-section {
    margin-top: 1.5rem;
}

.output-section h3 {
    color: var(--text);
    margin-bottom: 0.75rem;
    font-size: 1rem;
    font-weight: 600;
}

/* ---------- Alert ---------- */
.alert {
    padding: 0.85rem 1.25rem;
    border-radius: var(--radius-md);
    margin: 1rem 0;
    font-weight: 500;
    font-size: 0.9rem;
    animation: slideDown 0.3s ease-out;
}

.alert.success {
    background: #F0FFF4;
    color: #276749;
    border: 1px solid #C6F6D5;
}

/* ---------- Footer ---------- */
footer {
    background: var(--text);
    color: #CBD5E0;
    padding: 3rem 0 2rem;
    margin-top: auto;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr;
    gap: 3rem;
}

.footer-brand h3 {
    color: #FFF;
    font-size: 1.15rem;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.footer-brand p {
    font-size: 0.85rem;
    line-height: 1.6;
    color: #A0AEC0;
}

.footer-links h4 {
    color: #FFF;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.4rem;
}

.footer-links a {
    color: #A0AEC0;
    text-decoration: none;
    font-size: 0.85rem;
    transition: color var(--transition);
}

.footer-links a:hover {
    color: #FFF;
}

.footer-bottom {
    max-width: 1200px;
    margin: 2rem auto 0;
    padding: 1.25rem 2rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.footer-bottom p {
    font-size: 0.8rem;
    color: #718096;
}

.footer-bottom a {
    color: var(--primary-light);
    text-decoration: none;
    font-weight: 500;
}

.footer-bottom a:hover {
    color: #FFF;
}

/* ---------- Page Entrance for Tool Pages ---------- */
.tool-page-wrapper {
    padding: 0 2rem 3rem;
}

/* ---------- Scrollbar ---------- */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-soft);
}

::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 50px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}

/* ============================================================
   Responsive Design
   ============================================================ */
@media (max-width: 900px) {
    .tool-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-content {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {

    /* Hamburger Menu */
    .nav-toggle {
        display: block;
    }

    nav .container {
        padding: 0 1.25rem;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        height: 100vh;
        background: var(--bg);
        flex-direction: column;
        padding: 5rem 2rem 2rem;
        gap: 0.25rem;
        box-shadow: -10px 0 40px rgba(0, 0, 0, 0.15);
        transition: right var(--transition);
        z-index: 999;
        overflow-y: auto;
    }

    .nav-links.active {
        right: 0;
    }

    .nav-links a {
        padding: 0.75rem 1rem;
        font-size: 1rem;
        border-radius: var(--radius-sm);
        width: 100%;
    }

    .nav-links a.active::after {
        display: none;
    }

    .nav-links a.active {
        background: rgba(255, 122, 0, 0.08);
    }

    /* Overlay */
    .nav-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.3);
        z-index: 998;
    }

    .nav-overlay.active {
        display: block;
    }

    /* Hero */
    .hero {
        padding: 3rem 1.5rem 2rem;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .hero p {
        font-size: 1rem;
    }

    .hero-badges {
        gap: 1rem;
    }

    /* Tools */
    .tool-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .tool-card {
        flex-direction: row;
        text-align: left;
        padding: 1.25rem 1.5rem;
    }

    .tool-card-icon {
        width: 50px;
        height: 50px;
        font-size: 1.3rem;
    }

    .tool-card h3 {
        font-size: 1rem;
    }

    /* Features */
    .features-grid {
        grid-template-columns: 1fr 1fr;
        gap: 1.5rem;
    }

    /* Tool Pages */
    .tool-section {
        padding: 1.75rem 1.25rem;
        margin: -0.5rem 1rem 2rem;
        border-radius: var(--radius-md);
    }

    .tool-page-header h1 {
        font-size: 1.6rem;
    }

    .btn-group {
        flex-direction: column;
    }

    button,
    .btn {
        width: 100%;
        justify-content: center;
    }

    .stats {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Footer */
    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }

    /* Ad */
    .ad-banner {
        margin: 0 1rem;
    }

    .ad-banner-content {
        flex-direction: column;
        text-align: center;
    }

    .ad-banner-text {
        text-align: center;
    }
}

@media (max-width: 480px) {
    .hero h1 {
        font-size: 1.65rem;
    }

    .stats {
        grid-template-columns: 1fr;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .tool-section {
        padding: 1.5rem 1rem;
        margin: -0.5rem 0.5rem 2rem;
    }
}