/* ============================================
   FREE SEO TOOLS - shared styles
   Reuses :root vars from style.css (--primary-color, --text-color, etc.)
   ============================================ */

.tl-hero {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 60%, #005F6B 100%);
    color: #fff;
    padding: 3.5rem 1rem 3rem;
    text-align: center;
}

.tl-hero .breadcrumb {
    justify-content: center;
    margin-bottom: 1rem;
    color: rgba(255,255,255,.85);
}

.tl-hero .breadcrumb a { color: #fff; }
.tl-hero .breadcrumb span { color: rgba(255,255,255,.6); }

.tl-badge {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    background: rgba(255,255,255,.15);
    border: 1px solid rgba(255,255,255,.3);
    padding: .35rem .9rem;
    border-radius: 50px;
    font-size: .82rem;
    font-weight: 600;
    margin-bottom: 1.1rem;
}

.tl-hero h1 {
    font-size: clamp(1.6rem, 3.5vw, 2.4rem);
    font-weight: 800;
    margin: 0 0 .75rem;
    line-height: 1.25;
}

.tl-hero p {
    max-width: 680px;
    margin: 0 auto;
    opacity: .95;
    line-height: 1.6;
}

.tl-wrap {
    max-width: 900px;
    margin: 0 auto;
    padding: 2.5rem 1rem 1rem;
}

.tl-wrap.tl-wide { max-width: 1200px; }

/* Grid of tool cards on /tools/ index */
.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.5rem;
    margin: 1.5rem 0 3rem;
}

.tl-card {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-lg);
    padding: 1.5rem;
    box-shadow: var(--shadow);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.tl-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-3px);
}

.tl-card-icon {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    background: rgba(10,147,150,.1);
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: .9rem;
}

.tl-card h3 {
    font-size: 1.1rem;
    margin: 0 0 .5rem;
    color: var(--text-color);
}

.tl-card p {
    color: var(--text-light);
    font-size: .92rem;
    line-height: 1.55;
    margin: 0 0 1rem;
    flex-grow: 1;
}

/* Panel / tool UI box */
.tl-panel {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow);
    padding: 1.75rem;
    margin-bottom: 2rem;
}

.tl-panel h2 {
    font-size: 1.3rem;
    margin: 0 0 1.25rem;
    color: var(--text-color);
}

.tl-field { margin-bottom: 1.25rem; }

.tl-field label {
    display: block;
    font-weight: 600;
    font-size: .9rem;
    color: var(--text-color);
    margin-bottom: .4rem;
}

.tl-field .tl-hint {
    font-weight: 400;
    color: var(--text-light);
    font-size: .82rem;
}

.tl-input,
.tl-textarea,
.tl-select {
    width: 100%;
    padding: .7rem .9rem;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-family: var(--font-family);
    font-size: .95rem;
    color: var(--text-color);
    background: #fff;
    transition: var(--transition);
}

.tl-input:focus,
.tl-textarea:focus,
.tl-select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(10,147,150,.12);
}

.tl-textarea { resize: vertical; min-height: 110px; }

.tl-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1rem;
}

.tl-actions {
    display: flex;
    flex-wrap: wrap;
    gap: .75rem;
    align-items: center;
    margin-top: .5rem;
}

.tl-counter {
    font-size: .82rem;
    color: var(--text-light);
    margin-top: .35rem;
}

.tl-counter.tl-warn { color: var(--accent-color); font-weight: 600; }
.tl-counter.tl-over { color: #d9455f; font-weight: 600; }

.tl-result-box {
    position: relative;
    margin-top: .5rem;
}

.tl-result {
    width: 100%;
    padding: .9rem 1rem;
    border: 1px dashed var(--border-color);
    border-radius: var(--border-radius);
    background: var(--background-color);
    font-family: 'Menlo', 'Consolas', monospace;
    font-size: .85rem;
    line-height: 1.5;
    color: var(--text-color);
    white-space: pre-wrap;
    word-break: break-all;
    resize: vertical;
    min-height: 90px;
}

.tl-copy-btn {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    padding: .55rem 1rem;
    background: var(--white);
    color: var(--primary-color);
    border: 1.5px solid var(--primary-color);
    border-radius: var(--border-radius);
    font-weight: 600;
    font-size: .88rem;
    cursor: pointer;
    transition: var(--transition);
}

.tl-copy-btn:hover { background: var(--primary-color); color: #fff; }
.tl-copy-btn.tl-copied { background: #1a9c5e; border-color: #1a9c5e; color: #fff; }

/* SERP / OG preview widgets */
.tl-preview {
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 1rem 1.1rem;
    background: #fff;
    margin-bottom: .9rem;
}

.tl-preview-label {
    font-size: .75rem;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--text-light);
    font-weight: 700;
    margin-bottom: .6rem;
}

.tl-serp-url { color: #202124; font-size: .82rem; margin-bottom: .15rem; }
.tl-serp-title { color: #1a0dab; font-size: 1.15rem; line-height: 1.3; margin-bottom: .15rem; }
.tl-serp-desc { color: #4d5156; font-size: .87rem; line-height: 1.4; }

.tl-og-card {
    border: 1px solid var(--border-color);
    border-radius: 10px;
    overflow: hidden;
    max-width: 420px;
}

.tl-og-img {
    width: 100%;
    aspect-ratio: 1.91 / 1;
    background: var(--background-color) center/cover no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-light);
    font-size: .8rem;
}

.tl-og-body { padding: .8rem .9rem; background: #f7f9fa; }
.tl-og-domain { font-size: .72rem; text-transform: uppercase; color: var(--text-light); letter-spacing: .04em; }
.tl-og-title { font-weight: 700; color: var(--text-color); margin: .2rem 0; font-size: .95rem; }
.tl-og-desc { font-size: .82rem; color: var(--text-light); }

/* Info / explanation callout */
.tl-info {
    background: linear-gradient(135deg, #f0fffe, #fff);
    border: 1px solid #b2dfdb;
    border-radius: var(--border-radius-lg);
    padding: 1.25rem 1.5rem;
    margin-bottom: 2rem;
}

.tl-info h2 { font-size: 1.1rem; margin: 0 0 .6rem; color: var(--text-color); }
.tl-info p, .tl-info li { color: var(--text-light); font-size: .95rem; line-height: 1.65; }
.tl-info ul, .tl-info ol { margin: 0 0 0 1.25rem; }

/* Related tools interlink */
.tl-related {
    margin: 2.5rem 0;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
}

.tl-related h2 { font-size: 1.2rem; margin: 0 0 1rem; color: var(--text-color); }

.tl-related-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
}

.tl-related-card {
    display: block;
    padding: 1rem 1.1rem;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    color: var(--text-color);
    font-weight: 600;
    font-size: .92rem;
    transition: var(--transition);
}

.tl-related-card span {
    display: block;
    font-weight: 400;
    color: var(--text-light);
    font-size: .82rem;
    margin-top: .3rem;
}

.tl-related-card:hover {
    border-color: var(--primary-color);
    background: rgba(10,147,150,.04);
    color: var(--text-color);
}

@media (max-width: 640px) {
    .tl-panel { padding: 1.25rem; }
    .tl-wrap { padding: 2rem 1rem 1rem; }
}
