/**************************/
/* TUTORIAIS — LISTA */
/**************************/

.tuts-hero {
    background-image: linear-gradient(to right, rgba(20, 25, 32, 0.9), rgba(64, 45, 143, 0.55)),
        url('/assets/images/home/quem-somos-1.jpg');
    background-position: center;
    background-size: cover;
    padding: 12rem 0 8rem;
    color: #f8f9fa;
}
.tuts-hero-inner { max-width: 78rem; display: flex; flex-direction: column; gap: 1.4rem; text-align: left; }
.tuts-hero span.tuts-eyebrow {
    display: inline-block; color: #b08bff; font-weight: 700;
    font-size: 1.4rem; letter-spacing: 0.2rem; text-transform: uppercase;
}
.tuts-hero h1 { font-size: 5.2rem; line-height: 1.1; font-weight: 800; letter-spacing: -.1rem; }
.tuts-hero p { font-size: 1.8rem; line-height: 1.55; color: rgba(248,249,250,.85); max-width: 60rem; }

/* Barra de pesquisa + filtros (reaproveita padrão dos eventos) */
.tuts-filtros { padding: 4.8rem 0 0; }
.tuts-pesquisa {
    max-width: 60rem; margin: 0 auto 3.2rem; position: relative;
    display: flex; align-items: center; gap: 0.8rem;
    background: #fff; border: 2px solid #e3e7ef; border-radius: 10rem;
    padding: 0.6rem 0.8rem 0.6rem 2rem;
    box-shadow: 0 1px 12px 1px rgba(110, 76, 245, 0.06);
    transition: border-color 0.2s;
}
.tuts-pesquisa:focus-within { border-color: #6e4cf5; }
.tuts-pesquisa > ion-icon { color: #6e4cf5; font-size: 2rem; flex-shrink: 0; }
.tuts-pesquisa input {
    flex: 1; border: none; outline: none; background: transparent;
    font-size: 1.5rem; color: #1f2839; padding: 0.8rem 0; font-family: inherit;
}
.tuts-pesquisa input::placeholder { color: #9aa4b6; }
.tuts-pesquisa button {
    background: #6e4cf5; color: #fff; border: none;
    padding: 1.1rem 2.4rem; border-radius: 10rem;
    font-weight: 700; font-size: 1.3rem; cursor: pointer;
    transition: background 0.2s; font-family: inherit;
}
.tuts-pesquisa button:hover { background: #5839cf; }
.tuts-pesquisa-limpar {
    background: #f1f3f9; color: #6e7c95; width: 3rem; height: 3rem;
    border-radius: 50%; display: flex; align-items: center; justify-content: center;
    text-decoration: none; transition: all 0.2s;
}
.tuts-pesquisa-limpar:hover { background: #e3e7ef; color: #1f2839; }
.tuts-pesquisa-limpar ion-icon { font-size: 1.6rem; }

.tuts-filtros-list { display: flex; flex-wrap: wrap; gap: 1rem; justify-content: center; margin-bottom: 3.2rem; }
.tut-filtro {
    display: inline-flex; align-items: center; gap: 0.6rem;
    padding: 1rem 2rem; background-color: #f1f3f9; color: #45536d;
    text-decoration: none; border-radius: 10rem;
    font-size: 1.3rem; font-weight: 600; transition: all 0.3s;
    border: 2px solid transparent;
}
.tut-filtro:hover { background-color: #e3e7ef; }
.tut-filtro.ativo { background-color: #6e4cf5; color: #fff; }

/* Destaque no topo */
.tuts-section { padding: 4rem 0 9.6rem; }
.tut-destaque {
    display: grid; grid-template-columns: 1.1fr 1fr; gap: 4rem;
    background: #fff; border-radius: 2.4rem; overflow: hidden;
    box-shadow: 0 6px 30px 1px rgba(110, 76, 245, 0.12);
    margin-bottom: 6.4rem; text-decoration: none; color: inherit;
    transition: transform 0.3s ease;
}
.tut-destaque:hover { transform: translateY(-4px); }
.tut-destaque-img { aspect-ratio: 4/3; overflow: hidden; background: #f0edfe; }
.tut-destaque-img img { width: 100%; height: 100%; object-fit: cover; }
.tut-destaque-corpo { padding: 4rem 4rem 4rem 0; display: flex; flex-direction: column; gap: 1.6rem; justify-content: center; }
.tut-destaque-badge {
    display: inline-block; padding: 0.5rem 1.4rem; background: #6e4cf5;
    color: #fff; font-size: 1.1rem; font-weight: 700; letter-spacing: 0.1rem;
    text-transform: uppercase; border-radius: 10rem; width: fit-content;
}
.tut-destaque h2 { font-size: 3.2rem; line-height: 1.2; color: #1f2839; font-weight: 800; }
.tut-destaque p { font-size: 1.6rem; line-height: 1.6; color: #45536d; }
.tut-destaque-meta { display: flex; gap: 2rem; color: #6e7c95; font-size: 1.3rem; font-weight: 500; }
.tut-destaque-meta span { display: inline-flex; align-items: center; gap: 0.6rem; }

/* Grid */
.tuts-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 3.2rem; }
.tut-card {
    background: #fff; border-radius: 1.8rem; overflow: hidden;
    box-shadow: 0 1px 12px 1px rgba(110, 76, 245, 0.08);
    transition: all 0.3s ease; display: flex; flex-direction: column;
    text-decoration: none; color: inherit;
}
.tut-card:hover { transform: translateY(-6px); box-shadow: 0 6px 30px 1px rgba(110, 76, 245, 0.18); }
.tut-card-img { position: relative; aspect-ratio: 16/10; overflow: hidden; background: #f0edfe; }
.tut-card-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s; }
.tut-card:hover .tut-card-img img { transform: scale(1.06); }
.tut-card-img-placeholder {
    width: 100%; height: 100%; display: flex; align-items: center; justify-content: center;
    color: #b3bcc9; font-size: 4rem;
}
.tut-card-tipo {
    position: absolute; top: 1.4rem; left: 1.4rem;
    background: rgba(110, 76, 245, 0.95); color: #fff;
    padding: 0.5rem 1.2rem; border-radius: 10rem;
    font-size: 1.1rem; font-weight: 700; text-transform: uppercase;
    letter-spacing: 0.05rem;
}
.tut-card-yt {
    position: absolute; top: 1.4rem; right: 1.4rem;
    background: rgba(220,38,38,.95); color: #fff;
    width: 3.2rem; height: 3.2rem; border-radius: 50%;
    display: flex; align-items: center; justify-content: center; font-size: 1.5rem;
}
.tut-card-corpo { padding: 2rem; flex: 1; display: flex; flex-direction: column; gap: 1rem; }
.tut-card h3 { font-size: 1.9rem; line-height: 1.3; color: #1f2839; font-weight: 700; }
.tut-card-resumo { color: #45536d; font-size: 1.4rem; line-height: 1.55; flex: 1; }
.tut-card-meta {
    display: flex; gap: 1.4rem; color: #6e7c95; font-size: 1.2rem; font-weight: 500;
    padding-top: 1rem; border-top: 1px solid #f0edfe; margin-top: auto;
}
.tut-card-meta span { display: inline-flex; align-items: center; gap: 0.4rem; }

.tuts-vazio {
    grid-column: 1 / -1; text-align: center; padding: 8rem 2rem; color: #6e7c95;
}
.tuts-vazio ion-icon { font-size: 7.2rem; color: #b3bcc9; margin: 0 auto 2rem; display: block; width: 7.2rem; }
.tuts-vazio h3 { font-size: 2.4rem; color: #1f2839; font-weight: 700; margin-bottom: 1rem; }
.tuts-vazio p { font-size: 1.6rem; line-height: 1.5; color: #6e7c95; }

.tuts-paginacao { margin-top: 4.8rem; display: flex; justify-content: center; }

/**************************/
/* TUTORIAL — DETALHE */
/**************************/

.tut-hero {
    background: linear-gradient(135deg, #1a0e3e 0%, #231452 50%, #2d1b69 100%);
    color: #fff; padding: 8rem 0 6.4rem; position: relative; overflow: hidden;
}
.tut-hero::before {
    content: ''; position: absolute; top: -20rem; right: -10rem;
    width: 50rem; height: 50rem; border-radius: 50%;
    background: radial-gradient(circle, rgba(110, 76, 245, 0.25) 0%, transparent 70%);
}
.tut-hero-inner { position: relative; z-index: 1; max-width: 82rem; margin: 0 auto; text-align: center; }
.tut-hero-badges { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; margin-bottom: 2rem; }
.tut-hero-badge {
    display: inline-flex; align-items: center; gap: 0.6rem;
    background: rgba(255,255,255,.15); backdrop-filter: blur(10px);
    padding: 0.6rem 1.6rem; border-radius: 10rem;
    font-size: 1.2rem; font-weight: 600; letter-spacing: 0.05rem;
    border: 1px solid rgba(255,255,255,.15);
}
.tut-hero h1 { font-size: 4.4rem; line-height: 1.15; font-weight: 800; margin-bottom: 2rem; }
.tut-hero-resumo { font-size: 1.8rem; line-height: 1.55; opacity: 0.85; max-width: 68rem; margin: 0 auto 3rem; }
.tut-hero-meta {
    display: flex; gap: 3.2rem; justify-content: center; flex-wrap: wrap;
    font-size: 1.4rem; color: rgba(255,255,255,.75);
}
.tut-hero-meta span { display: inline-flex; align-items: center; gap: 0.8rem; }
.tut-hero-meta ion-icon { color: #b08bff; font-size: 1.8rem; }

/* Vídeo (topo do conteúdo) */
.tut-video-wrap { max-width: 96rem; margin: -4rem auto 0; padding: 0 2rem; position: relative; z-index: 2; }
.tut-video {
    aspect-ratio: 16 / 9; border-radius: 2rem; overflow: hidden;
    box-shadow: 0 20px 60px rgba(0,0,0,.4); background: #000;
}
.tut-video iframe { width: 100%; height: 100%; border: 0; }

/* Corpo (2 colunas) */
.tut-body { padding: 6.4rem 0 9.6rem; }
.tut-body-grid {
    display: grid; grid-template-columns: 1fr 28rem; gap: 4.8rem;
    max-width: 120rem; margin: 0 auto;
}
.tut-conteudo {
    font-size: 1.7rem; line-height: 1.8; color: #1f2839; max-width: 76rem;
}
.tut-conteudo p { margin-bottom: 1.8rem; }
.tut-conteudo h2 {
    font-size: 2.8rem; margin: 4.8rem 0 1.6rem; color: #1f2839;
    line-height: 1.25; font-weight: 800; scroll-margin-top: 12rem;
}
.tut-conteudo h3 {
    font-size: 2.2rem; margin: 3.6rem 0 1.2rem; color: #1f2839;
    line-height: 1.3; font-weight: 700; scroll-margin-top: 12rem;
}
.tut-conteudo ul, .tut-conteudo ol { padding-left: 2.4rem; margin-bottom: 1.8rem; }
.tut-conteudo li { margin-bottom: 0.6rem; }
.tut-conteudo a { color: #6e4cf5; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.tut-conteudo a:hover { color: #402d8f; }
.tut-conteudo strong { color: #1f2839; font-weight: 700; }
.tut-conteudo img {
    max-width: 100%; height: auto; border-radius: 1.4rem;
    margin: 2.4rem 0; box-shadow: 0 4px 20px rgba(31, 40, 57, 0.1);
}
.tut-conteudo blockquote {
    border-left: 4px solid #6e4cf5; padding: 1rem 2rem;
    background: rgba(110, 76, 245, 0.06); border-radius: 0 1.2rem 1.2rem 0;
    margin: 2.4rem 0; font-style: italic; color: #45536d;
}
.tut-conteudo pre {
    background: #0f172a; color: #e5e7eb; padding: 2rem;
    border-radius: 1.4rem; overflow-x: auto;
    font-family: ui-monospace, "SF Mono", Menlo, monospace;
    font-size: 1.35rem; line-height: 1.6; margin: 2.4rem 0;
}
.tut-conteudo code {
    background: rgba(110, 76, 245, 0.1); color: #402d8f;
    padding: 0.2rem 0.6rem; border-radius: 0.5rem;
    font-family: ui-monospace, "SF Mono", Menlo, monospace;
    font-size: 0.9em; font-weight: 500;
}
.tut-conteudo pre code { background: transparent; color: inherit; padding: 0; font-size: 1em; font-weight: 400; }
.tut-conteudo table { width: 100%; border-collapse: collapse; margin: 2.4rem 0; }
.tut-conteudo th, .tut-conteudo td { border: 1px solid #e3e7ef; padding: 1rem 1.4rem; text-align: left; }
.tut-conteudo th { background: #f8f9fb; font-weight: 700; color: #1f2839; }

/* Sidebar */
.tut-sidebar { position: sticky; top: 12rem; align-self: start; display: flex; flex-direction: column; gap: 2rem; }
.tut-side-card {
    background: #f8f9fb; border-radius: 0; padding: 2rem;
    border-left: 4px solid #6e4cf5;
}
.tut-side-card h4 { font-size: 1.4rem; color: #1f2839; margin-bottom: 1.2rem; text-transform: uppercase; letter-spacing: 0.1rem; }
.tut-side-card-plain { background: #f8f9fb; }

/* TOC */
.tut-toc ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 0.5rem; }
.tut-toc a {
    display: block; padding: 0.6rem 0.8rem; font-size: 1.3rem;
    color: #45536d; text-decoration: none; border-radius: 0;
    border-left: 2px solid transparent; transition: all 0.2s;
    line-height: 1.4;
}
.tut-toc a:hover { color: #6e4cf5; background: rgba(110, 76, 245, 0.06); border-left-color: #6e4cf5; }
.tut-toc a.toc-h3 { padding-left: 2rem; font-size: 1.25rem; }

/* GitHub card */
.tut-github {
    background: #1f2839; color: #fff; border-radius: 1.4rem;
    padding: 2rem; text-decoration: none; display: block;
    transition: transform 0.2s;
}
.tut-github:hover { transform: translateY(-2px); }
.tut-github-header { display: flex; align-items: center; gap: 1rem; margin-bottom: 1rem; }
.tut-github-header i { font-size: 2.4rem; }
.tut-github-header span { font-size: 1.2rem; color: rgba(255,255,255,.6); text-transform: uppercase; letter-spacing: 0.1rem; font-weight: 600; }
.tut-github-repo { font-size: 1.4rem; font-family: ui-monospace, Menlo, monospace; word-break: break-all; margin-bottom: 1rem; }
.tut-github-cta { display: inline-flex; align-items: center; gap: 0.6rem; font-size: 1.3rem; font-weight: 600; color: #b08bff; }

/* Share */
.tut-share { display: flex; gap: 0.8rem; flex-wrap: wrap; align-items: center; }
.tut-share-copy {
    display: inline-flex; align-items: center; gap: 0.8rem;
    padding: 1rem 1.6rem; border-radius: 10rem;
    background: #fff; color: #6e4cf5;
    border: 1px solid #e7e3f4; cursor: pointer;
    font-size: 1.3rem; font-weight: 600; font-family: inherit;
    transition: all 0.2s;
    box-shadow: 0 1px 8px 1px rgba(110, 76, 245, 0.08);
}
.tut-share-copy ion-icon { font-size: 1.6rem; }
.tut-share-copy:hover { background: #6e4cf5; color: #fff; border-color: #6e4cf5; }
.tut-share-copy.is-copied { background: #10b981; color: #fff; border-color: #10b981; }

/* Botão copiar em blocos de código */
.tut-code-block { position: relative; }
.tut-code-copy {
    position: absolute; top: 1rem; right: 1rem;
    display: inline-flex; align-items: center; gap: 0.5rem;
    padding: 0.5rem 1rem; border-radius: 0.8rem;
    background: rgba(255,255,255,0.08); color: #e5e7eb;
    border: 1px solid rgba(255,255,255,0.15); cursor: pointer;
    font-size: 1.15rem; font-weight: 600; font-family: inherit;
    opacity: 0.6; transition: all 0.2s;
}
.tut-code-block:hover .tut-code-copy { opacity: 1; }
.tut-code-copy:hover { background: rgba(255,255,255,0.15); }
.tut-code-copy.is-copied { background: #10b981; color: #fff; border-color: #10b981; opacity: 1; }
.tut-code-copy ion-icon { font-size: 1.3rem; }

/* Tags */
.tut-tags { display: flex; flex-wrap: wrap; gap: 0.6rem; }
.tut-tag {
    display: inline-block; padding: 0.4rem 1rem; background: #fff; color: #6e4cf5;
    font-size: 1.2rem; font-weight: 600; border-radius: 10rem;
    border: 1px solid #e7e3f4;
}

/* Autor pill */
.tut-autor {
    display: flex; align-items: center; gap: 1.2rem;
    padding: 1.2rem 1.4rem; background: #fff; border-radius: 1.2rem;
    box-shadow: 0 1px 8px 1px rgba(110, 76, 245, 0.08);
}
.tut-autor-avatar {
    width: 4rem; height: 4rem; border-radius: 50%;
    background: linear-gradient(135deg, #6e4cf5, #402d8f);
    color: #fff; display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 1.4rem;
}
.tut-autor-nome { font-size: 1.4rem; font-weight: 700; color: #1f2839; line-height: 1.2; }
.tut-autor-cargo { font-size: 1.2rem; color: #6e7c95; }

/* Relacionados */
.tut-relacionados { padding: 6.4rem 0 9.6rem; background: #f8f9fb; }
.tut-relacionados-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2.4rem; margin-top: 4rem; }

/**************************/
/* RESPONSIVO */
/**************************/

@media (max-width: 968px) {
    .tuts-grid, .tut-relacionados-grid { grid-template-columns: repeat(2, 1fr); }
    .tut-destaque { grid-template-columns: 1fr; }
    .tut-destaque-corpo { padding: 3.2rem; }
    .tut-body-grid { grid-template-columns: 1fr; gap: 3.2rem; }
    .tut-sidebar { position: static; }
    .tut-hero h1 { font-size: 3.4rem; }
    .tuts-hero h1 { font-size: 3.8rem; }
}
@media (max-width: 600px) {
    .tuts-hero { padding: 8rem 0 6rem; }
    .tuts-hero h1 { font-size: 3rem; }
    .tut-hero h1 { font-size: 2.6rem; }
    .tut-hero-meta { gap: 1.4rem; font-size: 1.2rem; }
    .tut-conteudo { font-size: 1.55rem; }
    .tuts-grid, .tut-relacionados-grid { grid-template-columns: 1fr; }
}
