/* ===== TOOLSWORLDHUB - MAIN STYLESHEET ===== */
@import url('https://fonts.googleapis.com/css2?family=Syne:wght@400;500;600;700;800&family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;0,9..40,600;1,9..40,400&display=swap');

:root {
  --primary: #0A0A0F;
  --secondary: #13131A;
  --surface: #1C1C27;
  --surface2: #25253A;
  --accent: #6C63FF;
  --accent2: #FF6584;
  --accent3: #43E97B;
  --text: #F0F0F8;
  --text2: #A0A0C0;
  --text3: #606080;
  --border: rgba(108,99,255,0.2);
  --border2: rgba(255,255,255,0.06);
  --glow: rgba(108,99,255,0.3);
  --radius: 16px;
  --radius-sm: 10px;
  --radius-lg: 24px;
  --shadow: 0 8px 32px rgba(0,0,0,0.4);
  --shadow-accent: 0 0 40px rgba(108,99,255,0.25);
  --transition: all 0.3s cubic-bezier(0.4,0,0.2,1);
  --font-display: 'Syne', sans-serif;
  --font-body: 'DM Sans', sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body { font-family: var(--font-body); background: var(--primary); color: var(--text); line-height: 1.6; overflow-x: hidden; min-height: 100vh; }
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--primary); }
::-webkit-scrollbar-thumb { background: var(--accent); border-radius: 3px; }
::selection { background: var(--accent); color: #fff; }
h1,h2,h3,h4,h5,h6 { font-family: var(--font-display); font-weight: 700; line-height: 1.2; }
h1 { font-size: clamp(2rem,5vw,3.8rem); }
h2 { font-size: clamp(1.6rem,3.5vw,2.6rem); }
h3 { font-size: clamp(1.1rem,2.5vw,1.5rem); }
p { color: var(--text2); line-height: 1.75; }
a { text-decoration: none; color: inherit; transition: var(--transition); }
img { max-width: 100%; height: auto; }
button { font-family: var(--font-body); }

.container { max-width: 1280px; margin: 0 auto; padding: 0 24px; }
.section { padding: 80px 0; }
.text-center { text-align: center; }
.hidden { display: none !important; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.flex { display: flex; }
.items-center { align-items: center; }
.gap-12 { gap: 12px; }
.gap-16 { gap: 16px; }
.w-full { width: 100%; }
.font-mono { font-family: 'Courier New', monospace; }
.text-accent { color: var(--accent); }
.text-green { color: var(--accent3); }
.text-pink { color: var(--accent2); }
.text-muted { color: var(--text3); }
.divider { height: 1px; background: var(--border2); margin: 24px 0; }
.gradient-text { background: linear-gradient(135deg, var(--accent), var(--accent2), var(--accent3)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }

/* NAVBAR */
.navbar { position: fixed; top: 0; left: 0; right: 0; z-index: 10001; padding: 14px 0; transition: var(--transition); border-bottom: 1px solid transparent; }
.navbar.scrolled { background: rgba(10,10,15,0.95); backdrop-filter: blur(20px); border-bottom-color: var(--border2); }
.nav-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.nav-logo { display: flex; align-items: center; gap: 10px; font-family: var(--font-display); font-size: 1.3rem; font-weight: 800; color: var(--text); cursor: pointer; }
.logo-icon { width: 36px; height: 36px; background: linear-gradient(135deg, var(--accent), var(--accent2)); border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 1rem; box-shadow: 0 0 20px var(--glow); }
.nav-logo span { color: var(--accent); }
.nav-links { display: flex; align-items: center; gap: 4px; list-style: none; }
.nav-links a { padding: 7px 13px; border-radius: var(--radius-sm); font-size: 0.88rem; font-weight: 500; color: var(--text2); transition: var(--transition); cursor: pointer; }
.nav-links a:hover, .nav-links a.active { color: var(--text); background: var(--surface); }
.nav-actions { display: flex; align-items: center; gap: 10px; }
.nav-toggle { display: none; background: none; border: 1px solid var(--border2); color: var(--text); cursor: pointer; padding: 6px 10px; font-size: 1.2rem; border-radius: var(--radius-sm); transition: var(--transition); }

/* BUTTONS */
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 10px 22px; border-radius: var(--radius-sm); font-size: 0.9rem; font-weight: 600; cursor: pointer; transition: var(--transition); border: none; outline: none; text-decoration: none; font-family: var(--font-body); }
.btn-primary { background: linear-gradient(135deg, var(--accent), #8B5CF6); color: #fff; box-shadow: 0 4px 20px var(--glow); }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 30px var(--glow); }
.btn-secondary { background: var(--surface); color: var(--text); border: 1px solid var(--border2); }
.btn-secondary:hover { background: var(--surface2); border-color: var(--accent); }
.btn-sm { padding: 7px 16px; font-size: 0.82rem; }
.btn-lg { padding: 14px 32px; font-size: 1rem; border-radius: var(--radius); }
.btn-ghost { background: transparent; color: var(--text2); }
.btn-ghost:hover { color: var(--text); background: var(--surface); }
.btn-success { background: linear-gradient(135deg, var(--accent3), #00c896); color: #000; }
.btn-danger { background: linear-gradient(135deg, var(--accent2), #ff4d6d); color: #fff; }
.btn-full { width: 100%; justify-content: center; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none !important; }

/* HERO */
.hero { min-height: 100vh; display: flex; align-items: center; position: relative; overflow: hidden; padding-top: 80px; }
.hero-bg { position: absolute; inset: 0; background: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(108,99,255,0.12) 0%, transparent 70%), radial-gradient(ellipse 40% 40% at 80% 80%, rgba(255,101,132,0.08) 0%, transparent 60%), radial-gradient(ellipse 40% 40% at 10% 60%, rgba(67,233,123,0.06) 0%, transparent 60%); }
.hero-grid { position: absolute; inset: 0; background-image: linear-gradient(var(--border2) 1px, transparent 1px), linear-gradient(90deg, var(--border2) 1px, transparent 1px); background-size: 60px 60px; mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 40%, transparent 100%); }
.hero-content { position: relative; z-index: 1; text-align: center; max-width: 920px; margin: 0 auto; }
.hero-badge { display: inline-flex; align-items: center; gap: 8px; padding: 6px 16px; background: rgba(108,99,255,0.1); border: 1px solid rgba(108,99,255,0.3); border-radius: 100px; font-size: 0.78rem; font-weight: 700; color: var(--accent); margin-bottom: 24px; letter-spacing: 0.08em; text-transform: uppercase; }
.hero-badge .dot { width: 6px; height: 6px; background: var(--accent3); border-radius: 50%; animation: pulse 2s infinite; }
@keyframes pulse { 0%,100%{ opacity:1; transform:scale(1); } 50%{ opacity:0.5; transform:scale(1.4); } }
.hero h1 { margin-bottom: 20px; }
.hero-desc { font-size: 1.05rem; max-width: 600px; margin: 0 auto 36px; color: var(--text2); }
.hero-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin-bottom: 48px; }
.hero-stats { display: flex; gap: 48px; justify-content: center; flex-wrap: wrap; margin-top: 48px; }
.stat-item { text-align: center; }
.stat-item .num { font-family: var(--font-display); font-size: 1.9rem; font-weight: 800; color: var(--text); display: block; }
.stat-item .label { font-size: 0.78rem; color: var(--text3); text-transform: uppercase; letter-spacing: 0.08em; }

/* SEARCH */
.search-wrapper { max-width: 560px; margin: 0 auto; position: relative; }
.search-bar { width: 100%; background: var(--surface); border: 1px solid var(--border2); border-radius: 100px; padding: 15px 56px 15px 22px; font-family: var(--font-body); font-size: 0.93rem; color: var(--text); outline: none; transition: var(--transition); }
.search-bar::placeholder { color: var(--text3); }
.search-bar:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(108,99,255,0.12); }
.search-btn { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); background: linear-gradient(135deg, var(--accent), #8B5CF6); border: none; border-radius: 50%; width: 38px; height: 38px; display: flex; align-items: center; justify-content: center; cursor: pointer; color: #fff; font-size: 0.95rem; transition: var(--transition); }
.search-btn:hover { transform: translateY(-50%) scale(1.1); }

/* SECTION HEADER */
.section-header { text-align: center; margin-bottom: 52px; }
.section-tag { display: inline-block; padding: 4px 14px; background: rgba(108,99,255,0.1); border: 1px solid rgba(108,99,255,0.25); border-radius: 100px; font-size: 0.75rem; font-weight: 700; color: var(--accent); text-transform: uppercase; letter-spacing: 0.1em; margin-bottom: 12px; }
.section-header h2 { margin-bottom: 10px; }
.section-header p { max-width: 500px; margin: 0 auto; font-size: 0.93rem; }

/* CATEGORY STRIP */
.categories-strip { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; margin-bottom: 36px; }
.cat-btn { padding: 8px 18px; border-radius: 100px; border: 1px solid var(--border2); background: var(--surface); color: var(--text2); font-size: 0.83rem; font-weight: 500; cursor: pointer; transition: var(--transition); font-family: var(--font-body); }
.cat-btn:hover, .cat-btn.active { background: var(--accent); border-color: var(--accent); color: #fff; }

/* TOOL CARDS */
.tools-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(268px, 1fr)); gap: 18px; }
.tool-card { background: var(--surface); border: 1px solid var(--border2); border-radius: var(--radius-lg); padding: 26px; cursor: pointer; transition: var(--transition); position: relative; overflow: hidden; display: flex; flex-direction: column; gap: 12px; }
.tool-card:hover { transform: translateY(-4px); border-color: var(--accent); box-shadow: var(--shadow-accent); }
.tool-icon { width: 50px; height: 50px; border-radius: 14px; display: flex; align-items: center; justify-content: center; font-size: 1.4rem; flex-shrink: 0; }
.tool-card h2 { font-size: 1rem; color: var(--text); }
.tool-card > p { font-size: 0.83rem; color: var(--text3); line-height: 1.5; flex: 1; }
.tool-card .tool-footer { display: flex; align-items: center; justify-content: space-between; margin-top: 4px; }
.tool-tag { padding: 3px 10px; border-radius: 100px; font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; }
.tag-ai { background: rgba(108,99,255,0.15); color: var(--accent); }
.tag-free { background: rgba(67,233,123,0.12); color: var(--accent3); }
.tag-popular { background: rgba(255,101,132,0.12); color: var(--accent2); }
.tool-arrow { color: var(--text3); font-size: 1.1rem; transition: var(--transition); }
.tool-card:hover .tool-arrow { color: var(--accent); transform: translateX(5px); }
.ic-purple { background: rgba(108,99,255,0.15); color: var(--accent); }
.ic-pink { background: rgba(255,101,132,0.15); color: var(--accent2); }
.ic-green { background: rgba(67,233,123,0.15); color: var(--accent3); }
.ic-orange { background: rgba(255,165,0,0.15); color: #FFA500; }
.ic-blue { background: rgba(0,163,255,0.15); color: #00A3FF; }
.ic-teal { background: rgba(0,210,200,0.15); color: #00D2C8; }
.ic-red { background: rgba(255,77,109,0.15); color: #FF4D6D; }
.ic-yellow { background: rgba(255,214,0,0.15); color: #FFD600; }
.ic-indigo { background: rgba(79,70,229,0.15); color: #4F46E5; }
.ic-cyan { background: rgba(6,182,212,0.15); color: #06B6D4; }

/* TOOL WORKSPACE */
.tool-header { background: linear-gradient(135deg, var(--surface) 0%, var(--secondary) 100%); border-bottom: 1px solid var(--border2); padding: 36px 0; margin-bottom: 36px; position: relative; overflow: hidden; }
.tool-header::before { content: ''; position: absolute; top: -50%; right: -10%; width: 360px; height: 360px; background: radial-gradient(circle, var(--glow) 0%, transparent 70%); pointer-events: none; }
.tool-header-inner { display: flex; align-items: center; gap: 18px; }
.tool-header-icon { width: 60px; height: 60px; border-radius: 16px; display: flex; align-items: center; justify-content: center; font-size: 1.7rem; flex-shrink: 0; }
.tool-header-text h1 { font-size: 1.8rem; }
.tool-header-text p { color: var(--text2); font-size: 0.9rem; }
.breadcrumb { display: flex; align-items: center; gap: 8px; font-size: 0.8rem; color: var(--text3); margin-bottom: 6px; }
.breadcrumb a { color: var(--text3); cursor: pointer; }
.breadcrumb a:hover { color: var(--accent); }
.tool-workspace { background: var(--surface); border: 1px solid var(--border2); border-radius: var(--radius-lg); padding: 30px; margin-bottom: 20px; }
.drop-zone { border: 2px dashed var(--border); border-radius: var(--radius); padding: 44px 24px; text-align: center; cursor: pointer; transition: var(--transition); background: var(--secondary); }
.drop-zone:hover, .drop-zone.dragover { border-color: var(--accent); background: rgba(108,99,255,0.05); }
.drop-zone .drop-icon { font-size: 2.8rem; margin-bottom: 10px; display: block; }
.drop-zone h2 { font-size: 1.05rem; color: var(--text); margin-bottom: 6px; }
.drop-zone p { font-size: 0.82rem; color: var(--text3); }
.file-input { display: none; }
.form-group { margin-bottom: 18px; }
.form-label { display: block; font-size: 0.83rem; font-weight: 600; color: var(--text2); margin-bottom: 7px; }
.form-input, .form-select, .form-textarea { width: 100%; background: var(--secondary); border: 1px solid var(--border2); border-radius: var(--radius-sm); padding: 11px 15px; font-family: var(--font-body); font-size: 0.9rem; color: var(--text); outline: none; transition: var(--transition); }
.form-input:focus, .form-select:focus, .form-textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(108,99,255,0.1); }
.form-textarea { resize: vertical; min-height: 120px; }
.form-select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23606080'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; background-size: 16px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.form-hint { font-size: 0.77rem; color: var(--text3); margin-top: 5px; }
.range-group { display: flex; align-items: center; gap: 12px; }
.range-input { flex: 1; -webkit-appearance: none; height: 4px; background: var(--surface2); border-radius: 2px; outline: none; }
.range-input::-webkit-slider-thumb { -webkit-appearance: none; width: 18px; height: 18px; border-radius: 50%; background: var(--accent); cursor: pointer; }
.range-val { min-width: 44px; text-align: center; font-weight: 600; color: var(--accent); font-size: 0.88rem; }
.progress-bar { background: var(--surface2); border-radius: 100px; height: 6px; overflow: hidden; margin: 12px 0; }
.progress-fill { height: 100%; border-radius: 100px; background: linear-gradient(90deg, var(--accent), var(--accent3)); transition: width 0.5s ease; width: 0%; }
.result-area { background: var(--secondary); border: 1px solid var(--border2); border-radius: var(--radius); padding: 22px; margin-top: 18px; display: none; }
.result-area.visible { display: block; }
.img-preview { max-width: 100%; max-height: 380px; border-radius: var(--radius-sm); display: block; margin: 0 auto; }

/* TOAST */
.toast-container { position: fixed; bottom: 24px; right: 24px; z-index: 9999; display: flex; flex-direction: column; gap: 8px; }
.toast { background: var(--surface2); border: 1px solid var(--border2); border-left: 4px solid var(--accent); border-radius: var(--radius-sm); padding: 13px 18px; min-width: 260px; display: flex; align-items: center; gap: 10px; font-size: 0.88rem; box-shadow: var(--shadow); animation: slideIn 0.3s ease; }
.toast.success { border-left-color: var(--accent3); }
.toast.error { border-left-color: var(--accent2); }
@keyframes slideIn { from { transform: translateX(110%); opacity:0; } to { transform:translateX(0); opacity:1; } }

/* CARD */
.card { background: var(--surface); border: 1px solid var(--border2); border-radius: var(--radius-lg); padding: 26px; transition: var(--transition); }

/* FEATURE ROW */
.features-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.feature-item { text-align: center; padding: 28px 18px; }
.feature-icon-wrap { width: 60px; height: 60px; border-radius: 16px; background: rgba(108,99,255,0.1); border: 1px solid rgba(108,99,255,0.2); display: flex; align-items: center; justify-content: center; font-size: 1.5rem; margin: 0 auto 14px; }
.feature-item h2 { font-size: 1rem; margin-bottom: 7px; }
.feature-item p { font-size: 0.83rem; color: var(--text3); }

/* FAQ */
.faq-item { border-bottom: 1px solid var(--border2); }
.faq-question { width: 100%; display: flex; align-items: center; justify-content: space-between; padding: 18px 0; background: none; border: none; color: var(--text); font-family: var(--font-display); font-size: 0.97rem; font-weight: 600; cursor: pointer; text-align: left; gap: 14px; }
.faq-question .chevron { transition: var(--transition); color: var(--text3); flex-shrink: 0; }
.faq-item.open .chevron { transform: rotate(180deg); color: var(--accent); }
.faq-answer { max-height: 0; overflow: hidden; transition: max-height 0.4s ease; }
.faq-answer p { padding-bottom: 18px; font-size: 0.88rem; color: var(--text3); }
.faq-item.open .faq-answer { max-height: 200px; }

/* FOOTER */
.footer { background: var(--secondary); border-top: 1px solid var(--border2); padding: 56px 0 24px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 36px; margin-bottom: 44px; }
.footer-brand > p { font-size: 0.83rem; color: var(--text3); max-width: 260px; margin: 12px 0 18px; }
.social-links { display: flex; gap: 8px; }
.social-link { width: 34px; height: 34px; border-radius: 9px; background: var(--surface); border: 1px solid var(--border2); display: flex; align-items: center; justify-content: center; color: var(--text3); font-size: 0.85rem; transition: var(--transition); }
.social-link:hover { color: #fff; background: var(--accent); border-color: var(--accent); }
.footer-col h2 { font-size: 0.78rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text3); margin-bottom: 14px; }
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 7px; }
.footer-col ul li a { color: var(--text3); font-size: 0.83rem; transition: var(--transition); cursor: pointer; }
.footer-col ul li a:hover { color: var(--text); }
.footer-bottom { border-top: 1px solid var(--border2); padding-top: 22px; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; }
.footer-bottom p { font-size: 0.8rem; color: var(--text3); }

/* PAGE LAYOUTS */
.page-hero { padding: 130px 0 56px; text-align: center; position: relative; }
.page-hero::before { content: ''; position: absolute; inset: 0; background: radial-gradient(ellipse 60% 60% at 50% 0%, rgba(108,99,255,0.1) 0%, transparent 70%); }
.page-hero h1, .page-hero p { position: relative; }
.page-hero > .container > p { max-width: 540px; margin: 12px auto 0; }
.content-block { max-width: 840px; margin: 0 auto; }
.content-block h2 { font-size: 1.35rem; margin: 34px 0 12px; color: var(--text); }
.content-block h3 { font-size: 1.05rem; margin: 22px 0 9px; color: var(--text); }
.content-block p { margin-bottom: 13px; font-size: 0.92rem; }
.content-block ul, .content-block ol { padding-left: 20px; margin-bottom: 13px; }
.content-block li { font-size: 0.92rem; color: var(--text2); margin-bottom: 5px; }
.content-block a { color: var(--accent); }

/* TABS */
.tabs { display: flex; gap: 3px; background: var(--secondary); padding: 4px; border-radius: var(--radius-sm); margin-bottom: 22px; flex-wrap: wrap; }
.tab-btn { flex: 1; min-width: 70px; padding: 9px 14px; border: none; border-radius: 8px; background: transparent; color: var(--text2); font-family: var(--font-body); font-size: 0.85rem; font-weight: 500; cursor: pointer; transition: var(--transition); white-space: nowrap; }
.tab-btn.active { background: var(--surface); color: var(--text); box-shadow: 0 2px 8px rgba(0,0,0,0.3); }
.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* IMG TOOL TABS */
.img-tool-tabs { display: flex; gap: 7px; flex-wrap: wrap; margin-bottom: 22px; }
.img-tool-tab { padding: 8px 16px; border-radius: 100px; border: 1px solid var(--border2); background: var(--surface); color: var(--text2); font-size: 0.83rem; cursor: pointer; transition: var(--transition); font-family: var(--font-body); }
.img-tool-tab.active { background: var(--accent); border-color: var(--accent); color: #fff; }

/* SPEED TEST */
.speed-gauge { text-align: center; padding: 28px; }
.gauge-circle { width: 180px; height: 180px; border-radius: 50%; background: conic-gradient(var(--accent) 0deg, var(--surface2) 0deg); display: flex; align-items: center; justify-content: center; margin: 0 auto 18px; position: relative; transition: background 1s ease; }
.gauge-circle::before { content: ''; position: absolute; width: 144px; height: 144px; border-radius: 50%; background: var(--surface); }
.gauge-inner { position: relative; z-index: 1; text-align: center; }
.gauge-inner .speed-num { font-family: var(--font-display); font-size: 2.2rem; font-weight: 800; color: var(--text); line-height: 1; }
.gauge-inner .speed-unit { font-size: 0.75rem; color: var(--text3); }
.speed-metrics { display: grid; grid-template-columns: repeat(3,1fr); gap: 13px; margin-top: 18px; }
.speed-metric { background: var(--secondary); border-radius: var(--radius-sm); padding: 14px; text-align: center; }
.speed-metric .m-val { font-family: var(--font-display); font-size: 1.2rem; font-weight: 700; color: var(--text); }
.speed-metric .m-label { font-size: 0.73rem; color: var(--text3); }

/* STRENGTH BAR */
.strength-bar { display: flex; gap: 4px; margin-top: 8px; }
.strength-seg { flex: 1; height: 4px; border-radius: 2px; background: var(--surface2); transition: var(--transition); }
.strength-label { font-size: 0.78rem; color: var(--text3); margin-top: 5px; }

/* SPINNER */
.spinner { width: 38px; height: 38px; border: 3px solid var(--surface2); border-top-color: var(--accent); border-radius: 50%; animation: spin 0.8s linear infinite; margin: 18px auto; }
@keyframes spin { to { transform: rotate(360deg); } }
.loading-text { text-align: center; color: var(--text2); font-size: 0.88rem; }

/* ALERT */
.alert { padding: 13px 17px; border-radius: var(--radius-sm); border-left: 4px solid; margin-bottom: 15px; font-size: 0.87rem; }
.alert-info { background: rgba(108,99,255,0.08); border-color: var(--accent); color: var(--text2); }
.alert-success { background: rgba(67,233,123,0.08); border-color: var(--accent3); color: var(--text2); }
.alert-warning { background: rgba(255,165,0,0.08); border-color: #FFA500; color: var(--text2); }

/* AI BADGE */
.ai-badge { display: inline-flex; align-items: center; gap: 6px; padding: 4px 11px; background: linear-gradient(135deg, rgba(108,99,255,0.2), rgba(255,101,132,0.2)); border: 1px solid rgba(108,99,255,0.3); border-radius: 100px; font-size: 0.73rem; font-weight: 700; color: var(--text); letter-spacing: 0.05em; }
.ai-badge::before { content: '✦'; color: var(--accent); font-size: 0.6rem; }

/* COPY BTN */
.copy-btn { display: inline-flex; align-items: center; gap: 6px; padding: 6px 13px; border-radius: 8px; background: var(--surface2); border: 1px solid var(--border2); color: var(--text2); font-size: 0.8rem; cursor: pointer; transition: var(--transition); font-family: var(--font-body); }
.copy-btn:hover { background: var(--accent); color: #fff; border-color: var(--accent); }

/* DETECTION */
.detection-meter { height: 11px; background: var(--surface2); border-radius: 100px; overflow: hidden; margin: 10px 0; }
.detection-fill { height: 100%; border-radius: 100px; transition: width 1s ease; }
.detection-fill.human { background: linear-gradient(90deg, var(--accent3), #00c896); }
.detection-fill.ai-gen { background: linear-gradient(90deg, var(--accent2), #ff4d6d); }
.detection-score { font-family: var(--font-display); font-size: 2.8rem; font-weight: 800; }

/* CONTACT */
.contact-grid { display: grid; grid-template-columns: 1fr 1.6fr; gap: 36px; }
.contact-info-item { display: flex; gap: 14px; margin-bottom: 22px; }
.ci-icon { width: 44px; height: 44px; border-radius: 11px; background: rgba(108,99,255,0.1); border: 1px solid rgba(108,99,255,0.2); display: flex; align-items: center; justify-content: center; font-size: 1rem; flex-shrink: 0; }
.contact-info-item h2 { font-size: 0.9rem; margin-bottom: 3px; }
.contact-info-item p { font-size: 0.83rem; color: var(--text3); }

/* TEAM */
.team-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 18px; }
.team-card { text-align: center; padding: 26px 18px; background: var(--surface); border-radius: var(--radius-lg); border: 1px solid var(--border2); transition: var(--transition); }
.team-card:hover { transform: translateY(-4px); border-color: var(--border); }
.team-avatar { width: 68px; height: 68px; border-radius: 50%; margin: 0 auto 12px; display: flex; align-items: center; justify-content: center; font-size: 1.7rem; }
.team-card h3 { font-size: 0.93rem; margin-bottom: 4px; }
.team-card p { font-size: 0.78rem; color: var(--text3); }

/* FADE IN ANIMATION */
.fade-in { opacity: 0; transform: translateY(20px); transition: opacity 0.55s ease, transform 0.55s ease; }
.fade-in.visible { opacity: 1; transform: translateY(0); }

/* RESUME PREVIEW */
.resume-preview-wrap { background: #fff; color: #111; border-radius: var(--radius-sm); padding: 30px; min-height: 380px; font-family: 'DM Sans', sans-serif; line-height: 1.5; }
.resume-preview-wrap h2 { color: #1a1a2e; font-size: 1.5rem; border-bottom: 2px solid #6C63FF; padding-bottom: 8px; margin-bottom: 16px; }
.resume-preview-wrap h3 { color: #6C63FF; font-size: 0.95rem; margin: 14px 0 5px; text-transform: uppercase; letter-spacing: 0.05em; }
.resume-preview-wrap p, .resume-preview-wrap li { color: #444; font-size: 0.85rem; }
.resume-section { margin-bottom: 18px; }

/* RESPONSIVE */
@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .features-row { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
  /* Show hamburger button, hide desktop CTA */
  .nav-toggle { display: flex !important; }
  .nav-actions .btn-primary { display: none; }

  /* ── MOBILE DRAWER: slides in from the RIGHT ── */
  .nav-links {
    /* Override ALL desktop flex/inline styles */
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    justify-content: flex-start !important;
    gap: 0 !important;

    /* Fixed full-height panel on the right side */
    position: fixed !important;
    top: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    left: auto !important;
    width: 280px !important;
    max-width: 85vw !important;

    /* Visual styling */
    background: var(--secondary) !important;
    border-left: 1px solid var(--border2) !important;
    padding: 70px 12px 24px !important;
    z-index: 9999 !important;
    overflow-y: auto !important;
    list-style: none !important;

    /* Slide animation: start off-screen to the right */
    transform: translateX(110%) !important;
    transition: transform 0.28s cubic-bezier(0.4, 0, 0.2, 1) !important;
    box-shadow: -6px 0 32px rgba(0,0,0,0.6) !important;

    /* Reset any inherited margin/border */
    margin: 0 !important;
    border-top: none !important;
    border-bottom: none !important;
    border-right: none !important;
  }

  /* Slide IN when open */
  .nav-links.open {
    transform: translateX(0) !important;
  }

  /* Nav link items inside the drawer */
  .nav-links li {
    display: block !important;
    width: 100% !important;
    border-bottom: 1px solid var(--border2);
  }
  .nav-links li:last-child { border-bottom: none; }

  .nav-links a {
    display: block !important;
    width: 100% !important;
    padding: 14px 16px !important;
    font-size: 0.95rem !important;
    font-weight: 500;
    color: var(--text2) !important;
    border-radius: 0 !important;
  }
  .nav-links a:hover, .nav-links a.active {
    background: var(--surface) !important;
    color: var(--text) !important;
  }

  /* Backdrop overlay (dark blur behind the drawer) */
  .nav-drawer-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.6);
    z-index: 9998;
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
  }
  .nav-drawer-backdrop.visible { display: block; }

  /* Force navbar bar opaque when drawer open */
  .navbar:has(.nav-links.open) {
    background: var(--secondary) !important;
    border-bottom-color: var(--border2) !important;
  }

  /* Scroll lock when drawer open */
  body.nav-open { overflow: hidden; position: fixed; width: 100%; }

  /* ── OTHER MOBILE LAYOUT FIXES ── */
  .hero-stats { gap: 28px; }
  .form-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .features-row { grid-template-columns: 1fr; }
  .speed-metrics { grid-template-columns: 1fr 1fr; }
  .tools-grid { grid-template-columns: 1fr 1fr; }
  .tool-workspace { padding: 18px; }
  .section { padding: 54px 0; }
  .tool-header { padding: 28px 0; margin-bottom: 26px; }
}
@media (max-width: 480px) {
  .container { padding: 0 14px; }
  .tools-grid { grid-template-columns: 1fr; }
  .tabs { flex-direction: column; }
  .speed-metrics { grid-template-columns: 1fr; }
  .hero-stats { gap: 20px; }
}

/* ===== CHIPS ===== */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { padding: 6px 14px; background: var(--surface2); border: 1px solid var(--border2); border-radius: 100px; font-size: 0.82rem; color: var(--text2); cursor: pointer; transition: var(--transition); font-family: var(--font-body); }
.chip:hover { border-color: var(--accent); color: var(--accent); }

/* ===== QR FIX ===== */
#qrResult { display: none; }
#qrResult.visible { display: block; }

/* ===== IMG SUBTOOL PANELS ===== */
.img-subtool { display: none; }
.img-subtool.active { display: block; }

/* ===== TWO-COLUMN TOOL LAYOUT — collapses to single column on mobile ===== */
.grid-2-col { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items: start; }
.qr-layout { display: grid; grid-template-columns: 1.2fr 1fr; gap: 24px; }
.wc-layout { display: grid; grid-template-columns: 1.3fr 1fr; gap: 24px; align-items: start; }
@media (max-width: 768px) {
  .grid-2-col, .qr-layout, .wc-layout { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
}

/* ===== SMALL STAT/METRIC GRIDS — 3-col desktop, 2-col tablet, stack on phones ===== */
@media (max-width: 600px) {
  .tool-workspace div[style*="1fr 1fr 1fr"] { grid-template-columns: 1fr 1fr !important; }
}
@media (max-width: 380px) {
  .tool-workspace div[style*="1fr 1fr 1fr"] { grid-template-columns: 1fr !important; }
}

/* ===== FLEX WRAP FIX ===== */
.flex-wrap { flex-wrap: wrap; }

/* ===== RESULT AREA FIX ===== */
.result-area { display: none; }
.result-area.visible { display: block; }

/* ===== LOGO CANVAS RESPONSIVE ===== */
#logoCanvas { max-width: 100%; height: auto; }

/* ================================================================
   NEW TOOLS — ADDITIONAL STYLES
   ================================================================ */

/* Color Picker */
input[type="color"] {
  -webkit-appearance: none;
  border: 2px solid var(--border2);
  border-radius: 12px;
  cursor: pointer;
  padding: 2px;
  background: var(--secondary);
  transition: var(--transition);
}
input[type="color"]:hover { border-color: var(--accent); }
input[type="color"]::-webkit-color-swatch-wrapper { padding: 0; border-radius: 8px; }
input[type="color"]::-webkit-color-swatch { border: none; border-radius: 8px; }

/* Word Counter */
#wcStats .card { padding: 16px 10px; }

/* JSON Formatter */
#jsonInput, #jsonOutput { tab-size: 2; }

/* Markdown preview */
#mdPreview pre { background: #1e1e2e; border-radius: 8px; overflow-x: auto; margin: 12px 0; }
#mdPreview h1,#mdPreview h2,#mdPreview h3,#mdPreview h4 { font-family: var(--font-display); }

/* Unit Converter */
#unitCategories { gap: 6px; }
#unitCategories .cat-btn { padding: 6px 14px; font-size: 0.8rem; }

/* Tool grid – icon text fix */
.tool-icon { font-size: 1.4rem; font-style: normal; font-weight: 700; }

/* Inline code color in dark */
.font-mono { letter-spacing: 0.03em; }

/* Tab panels smooth transition */
.tab-panel { animation: fadeUp 0.22s ease; }
@keyframes fadeUp { from { opacity:0; transform:translateY(8px); } to { opacity:1; transform:translateY(0); } }

/* Drop zone hover ring */
.drop-zone:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(108,99,255,0.12); }

/* Chip hover glow */
.chip:hover { box-shadow: 0 0 0 2px rgba(108,99,255,0.2); }

/* Result area smooth show */
.result-area { transition: opacity 0.3s ease; }
.result-area.visible { opacity: 1; }

/* Speed test animated gradient */
.gauge-circle { transition: background 0.6s ease; }

/* Smooth strength bar */
.strength-seg { transition: background 0.4s ease; }

/* Password input monospace */
#generatedPW { font-size: 0.9rem !important; letter-spacing: 0.06em; }

/* Footer nav links pointer */
.footer-col ul li a { cursor: pointer; }
.footer-col ul li a:hover { padding-left: 5px; color: var(--accent) !important; }

/* Markdown editor split view stacks on mobile, each pane keeps min height */
@media (max-width: 768px) {
  #markdownSplit { display: flex !important; flex-direction: column !important; }
  #markdownSplit > * { min-height: 320px; }
}

/* Back to top */
.back-to-top {
  position: fixed;
  bottom: 80px;
  right: 24px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  border: none;
  font-size: 1.1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px var(--glow);
  transition: var(--transition);
  opacity: 0;
  pointer-events: none;
  z-index: 500;
}
.back-to-top.visible { opacity: 1; pointer-events: all; }
.back-to-top:hover { transform: translateY(-3px); box-shadow: 0 8px 28px var(--glow); }

/* Loading skeleton shimmer */
.skeleton {
  background: linear-gradient(90deg, var(--surface) 25%, var(--surface2) 50%, var(--surface) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: var(--radius-sm);
}
@keyframes shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }

/* Glow on hover for tool header icon */
.tool-header-icon { transition: var(--transition); }
.tool-header-icon:hover { transform: scale(1.08); filter: brightness(1.15); }

/* Nav logo hover */
.nav-logo:hover .logo-icon { transform: rotate(-8deg) scale(1.1); }
.logo-icon { transition: transform 0.3s ease; }

/* Tooltip */
[title] { position: relative; }

/* JSON status colored */
#jsonStatus { min-height: 20px; }

/* Hero badge pulse glow */
.hero-badge { animation: badgePulse 3s ease infinite; }
@keyframes badgePulse { 0%,100% { box-shadow: 0 0 0 0 rgba(108,99,255,0); } 50% { box-shadow: 0 0 0 6px rgba(108,99,255,0.1); } }

/* Alert icon spacing */
.alert strong { margin-right: 4px; }

/* B64 file result */
#b64FileResult { display: none; }
#b64FileResult.visible { display: block; }

/* Table in markdown */
#mdPreview table { border-collapse: collapse; width: 100%; }

/* Img comparison canvas */
canvas { display: block; max-width: 100%; }

/* Smooth page transitions */
.page.active { animation: pageFadeIn 0.25s ease; }
@keyframes pageFadeIn { from { opacity: 0; } to { opacity: 1; } }

/* Number inputs */
input[type="number"] { -moz-appearance: textfield; }
input[type="number"]::-webkit-outer-spin-button,
input[type="number"]::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

/* Contact form valid feedback */
.form-input:valid:not(:placeholder-shown):not([type="color"]) { border-color: rgba(67,233,123,0.4); }
.form-input:invalid:not(:placeholder-shown):not([type="color"]) { border-color: rgba(255,101,132,0.4); }

/* Responsive tool grid final */
@media (max-width: 600px) {
  .tool-header-inner { flex-direction: column; align-items: flex-start; gap: 12px; }
  .speed-metrics { grid-template-columns: 1fr 1fr 1fr !important; }
  .gauge-circle { width: 150px; height: 150px; }
  .gauge-circle::before { width: 118px; height: 118px; }
  .gauge-inner .speed-num { font-size: 1.8rem; }
  .hero-stats .stat-item .num { font-size: 1.5rem; }
  .hero h1 { font-size: 1.8rem; }
}

/* ===== MULTI-PAGE LAYOUT: body flex col, footer always at bottom ===== */
body { display: flex; flex-direction: column; min-height: 100vh; }
main { flex: 1 0 auto; }
footer.footer { flex-shrink: 0; margin-top: auto; }

/* ===== UTILITY CLASSES ===== */
.mt-32 { margin-top: 32px; }
.mt-8  { margin-top: 8px; }

/* ===== FOOTER: social links removed, clean up spacing ===== */
.footer-brand > p { margin-bottom: 0; }

/* ===== FADE-IN ANIMATION DELAYS ===== */
.fade-delay-1 { transition-delay: 0.12s !important; }
.fade-delay-2 { transition-delay: 0.24s !important; }
.fade-delay-3 { transition-delay: 0.36s !important; }

/* ===== ACTIVE NAV LINK ===== */
.nav-links a.active { color: var(--text); background: var(--surface); }

/* ===== PAGE TOP SPACING — clears the fixed navbar ===== */
.page-top { padding-top: 80px; }
.page-hero { padding-top: 130px; padding-bottom: 56px; text-align: center; position: relative; }
.page-hero::before { content:''; position:absolute; inset:0; background:radial-gradient(ellipse 60% 60% at 50% 0%,rgba(108,99,255,.1) 0%,transparent 70%); pointer-events:none; }
.page-hero h1, .page-hero p { position: relative; }
.tool-header { /* base padding already set above; main.page-top provides navbar clearance */ }

/* ===== MOBILE FIXES ===== */
@media (max-width: 768px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 480px) {
  .footer-grid { grid-template-columns: 1fr; }
  .hero-stats { flex-wrap: wrap; gap: 18px; }
  .hero h1 { font-size: 1.8rem; }
}

/* ===== BACK TO TOP ===== */
.back-to-top { position:fixed; bottom:80px; right:24px; width:42px; height:42px; border-radius:50%; background:var(--accent); color:#fff; border:none; font-size:1.1rem; cursor:pointer; display:flex; align-items:center; justify-content:center; box-shadow:0 4px 20px var(--glow); transition:var(--transition); opacity:0; pointer-events:none; z-index:500; }
.back-to-top.visible { opacity:1; pointer-events:all; }
.back-to-top:hover { transform:translateY(-3px); }

