/*
Theme Name: Porta Studio
Theme URI: https://porta-folio.com
Author: Portafolio Creativo
Description: Theme minimalista estratégico para agencia creativa.
Version: 1.0
Text Domain: porta-studio
*/

/* =========================
   VARIABLES
========================= */

:root {
  --color-brand: #1e73be;
}

/* =========================
   RESET
========================= */

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

/* =========================
   BASE TIPOGRÁFICA
========================= */

body {
  font-family: "Trebuchet MS", Trebuchet, Arial, sans-serif;
  line-height: 1.75;
  color: #111;
  background: #fff;
}

/* Títulos principales */
h1,
.page-title,
.post-title,
.hero h1 {
  font-family: 'Archivo Black', sans-serif;
  letter-spacing: 0.5px;
}

/* Subtítulos */
h2, h3, h4 {
  font-family: 'Archivo', sans-serif;
  font-weight: 600;
}

/* Ritmo editorial */
.entry-content p,
.blog-post p,
.content-main p {
  margin-bottom: 1.5rem;
}

.entry-content h2,
.entry-content h3 {
  margin-top: 2.5rem;
  margin-bottom: 1rem;
}

/* Separación título de post */
.blog-post h1 {
  margin-top: 0;
}

.blog-sidebar-left,
.blog-sidebar-right,
.content-sidebar {
  padding-top: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

/* =========================
   CONTAINER
========================= */

.container {
  max-width: 1300px;
  margin: 0 auto;
  padding: 0 2rem;
}

/* =========================
   HEADER
========================= */

.site-header {
  background: #ffffff;
  border-bottom: 1px solid #eee;
}

.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 90px;
}

.site-logo img {
  height: 50px;
  width: auto;
  display: block;
  transition: transform 0.25s ease, filter 0.25s ease;
}

.site-logo:hover img {
  transform: translateY(-2px);
  filter: brightness(1.03);
}

.main-nav ul {
  list-style: none;
  display: flex;
  gap: 2rem;
}

.main-nav a {
  font-weight: 500;
  transition: opacity 0.3s ease;
}

.main-nav a:hover {
  opacity: 0.6;
}

/* =========================
   HERO
========================= */

.hero {
  padding: 3rem 2rem 4rem;
  text-align: center;
}

.hero-content {
  max-width: 900px;
  margin: auto;
}

.hero h1 {
  font-size: 3.2rem;
  line-height: 1.1;
  margin-bottom: 1.5rem;
}

.hero h2 {
  font-weight: 400;
  font-size: 1.6rem;
  opacity: 0.75;
}

/* =========================
   PROYECTOS
========================= */

.proyectos-section {
  margin-top: 6rem;
}

.section-title {
  text-align: center;
  margin-bottom: 3rem;
  font-size: 2.2rem;
}

.proyectos-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem;
}

.proyecto-card {
  position: relative;
  overflow: hidden;
}

.proyecto-card a {
  display: block;
  position: relative;
}

.proyecto-card img {
  width: 100%;
  height: 420px;
  object-fit: cover;
  display: block;
  transition: transform 0.6s ease;
}

.proyecto-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(0,0,0,0.75),
    rgba(0,0,0,0.1)
  );
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
}

.proyecto-card:hover img {
  transform: scale(1.05);
}

.proyecto-card:hover::after {
  opacity: 1;
}

/* =========================
   SERVICIOS
========================= */

.servicios-section {
  padding: 6rem 2rem;
}

.servicios-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3rem;
  margin-top: 3rem;
}

.servicio-item {
  display: block;
  border-bottom: 1px solid #eee;
  padding-bottom: 2rem;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.servicio-item:hover {
  transform: translateY(-6px);
  opacity: 0.85;
}

/* =========================
   BLOG (3 COLUMNAS)
========================= */

.blog-wrapper {
  display: grid;
  grid-template-columns: 220px 1fr 240px;
  max-width: 1300px;
  margin: 0 auto;
  padding: 2.5rem 2rem 4rem; /* 🔥 REGRESAMOS el padding superior */
  gap: 2.5rem;
  align-items: start;
}

/* Sidebar izquierdo */
.blog-sidebar-left {
  border-right: 1px solid #eee;
  padding-right: 1.5rem;
}

/* Categorías amarillo (como lo tenías) */
.blog-sidebar-left ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.blog-sidebar-left li {
  margin-bottom: 10px;
}

.blog-sidebar-left li a {
  display: inline-block;
  background: #efce00;
  padding: 6px 10px;
  font-size: 0.85rem;
  transition: background 0.2s ease, color 0.2s ease;
}

.blog-sidebar-left li a:hover {
  background: #e5e5e5;
  color: #111;
}

/* Sidebar derecho */
.blog-sidebar-right {
  border-left: 1px solid #eee;
  padding-left: 1.5rem;
  font-size: 0.9rem;
}

/* Contenido */
.blog-content {
  max-width: 850px;
}

.blog-post {
  margin-bottom: 4rem;
  border-bottom: 1px solid #eaeaea;
  padding-bottom: 3rem;
}

.blog-post h1 {
  margin-top: 0;
}

/* =========================
   PAGE (2 COLUMNAS)
========================= */

.content-wrapper {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 3rem;
  padding: 2rem 0 4rem;
}

.content-main {
  max-width: 850px;
}

.content-sidebar {
  border-left: 1px solid #eee;
  padding-left: 2rem;
  font-size: 0.9rem;
}

.page-header {
  margin-bottom: 2rem;
}

.page-title {
  font-size: 2.4rem;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.5px;
}

.sidebar-block {
  margin-bottom: 2.5rem;
}

.sidebar-block h3 {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 0.8rem;
  font-weight: 600;
}

.sidebar-block ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.sidebar-block li {
  margin-bottom: 0.5rem;
  opacity: 0.85;
}


/* =========================
   FOOTER
========================= */

.site-footer {
  margin-top: 6rem;
  padding: 3rem 0;
  text-align: center;
  border-top: 1px solid #eee;
  font-size: 0.9rem;
  opacity: 0.7;
}

/* =========================
   IMÁGENES CENTRADAS
========================= */

.entry-content img,
.content-main img {
  max-width: 100%;
  height: auto;
}

/* Gutenberg */
.wp-block-image {
  text-align: center;
  margin: 2rem 0;
}

.wp-block-image img {
  display: inline-block;
}

/* Editor clásico */
.aligncenter {
  display: block;
  margin: 2rem auto;
}

/* =========================
   FOOTER
========================= */

.site-footer {
  margin-top: 6rem;
  padding: 3rem 0;
  text-align: center;
  border-top: 1px solid #eee;
  font-size: 0.9rem;
  opacity: 0.7;
}

/* =========================
   RESPONSIVE
========================= */

@media (max-width: 1024px) {
  .proyectos-grid,
  .servicios-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .contacto-grid {
    grid-template-columns: 1fr;
  }

  .header-inner {
    height: 76px;
  }

  .site-logo img {
    height: 36px;
  }
}

@media (max-width: 640px) {
  .proyectos-grid,
  .servicios-grid {
    grid-template-columns: 1fr;
  }

  .hero {
    padding: 5rem 2rem 3rem;
  }

  .hero h1 {
    font-size: 2rem;
  }

  .hero h2 {
    font-size: 1.2rem;
  }
}

/* =========================
   SOCIAL SIDEBAR (HORIZONTAL)
========================= */

.social-block {
  margin-top: 2.5rem;
}

.sidebar-title {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 1.2rem;
  font-weight: 600;
}

.social-icons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
}

.social-icon img {
  width: 20px;
  height: 20px;
  filter: grayscale(100%);
  opacity: 0.7;
  transition: all 0.25s ease;
}

.social-icon:hover img {
  filter: none;
  opacity: 1;
  transform: translateY(-2px);
}

.blog-sidebar-left,
.blog-sidebar-right {
  padding-top: 0;
}

/* =========================
   COMMENTS AREA
========================= */

.comments-area {
  margin-top: 4rem;
  padding-top: 2rem;
  border-top: 1px solid #eee;
  max-width: 720px;
}

.comments-area h3 {
  font-size: 1.4rem;
  margin-bottom: 1rem;
}

/* =========================
   FORMULARIO
========================= */

.comment-form {
  margin-top: 2rem;
}

/* textarea */
.comment-form textarea {
  width: 100%;
  min-height: 140px;
  padding: 12px 14px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-family: inherit;
  font-size: 0.95rem;
  resize: vertical;
  transition: border-color .2s ease;
}

.comment-form textarea:focus {
  outline: none;
  border-color: var(--color-brand);
}

/* labels */
.comment-form label {
  display: block;
  font-weight: 600;
  font-size: 0.85rem;
  margin-bottom: 4px;
}

/* fila de campos */
.comment-form .comment-form-author,
.comment-form .comment-form-email,
.comment-form .comment-form-url {
  width: 32%;
  display: inline-block;
  vertical-align: top;
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"] {
  width: 100%;
  padding: 9px 10px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-family: inherit;
  font-size: 0.9rem;
  transition: border-color .2s ease;
}

.comment-form input:focus {
  outline: none;
  border-color: var(--color-brand);
}

/* espacio entre campos */
.comment-form .comment-form-author {
  margin-right: 2%;
}

.comment-form .comment-form-email {
  margin-right: 2%;
}

/* checkbox */
.comment-form .comment-form-cookies-consent {
  margin-top: 1rem;
  font-size: 0.85rem;
}

/* botón */
.comment-form input[type="submit"] {
  margin-top: 1.4rem;
  background: transparent;
  border: 2px solid var(--color-brand);
  color: var(--color-brand);
  padding: 10px 18px;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all .25s ease;
}

.comment-form input[type="submit"]:hover {
  background: var(--color-brand);
  color: #fff;
}


/* =========================
   COMENTARIOS PUBLICADOS
========================= */

.comment-list {
  margin-top: 3rem;
  list-style: none;
}

.comment-list li {
  margin-bottom: 2rem;
}

.comment-body {
  display: flex;
  gap: 14px;
}

/* avatar */
.comment-author img {
  border-radius: 50%;
  width: 38px;
  height: 38px;
}

/* contenido */
.comment-content {
  max-width: 620px;
}

.comment-author .fn {
  font-weight: 600;
}

.comment-metadata {
  font-size: 0.8rem;
  color: #777;
  margin-bottom: 6px;
}

.comment-content p {
  margin-bottom: 0.6rem;
}

/* reply */
.reply a {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--color-brand);
}

/* =========================
   COMMENTS EDITORIAL STYLE
========================= */

.comments-area {
  margin-top: 4rem;
  padding-top: 2.5rem;
  border-top: 1px solid #eee;
  max-width: 720px;
}

.comments-title {
  font-size: 1.5rem;
  margin-bottom: 2rem;
}

/* lista */

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

/* comentario individual */

.comment {
  padding: 1.8rem 0;
  border-bottom: 1px solid #f1f1f1;
}

.comment-body {
  display: flex;
  gap: 16px;
}

/* avatar */

.comment-author img {
  border-radius: 50%;
  width: 42px;
  height: 42px;
}

/* contenido */

.comment-content-wrapper {
  flex: 1;
}

/* autor */

.comment-author .fn {
  font-weight: 600;
  font-size: 0.95rem;
}

.comment-metadata {
  font-size: 0.8rem;
  color: #777;
  margin-top: 2px;
  margin-bottom: 10px;
}

/* texto */

.comment-content p {
  font-size: 0.95rem;
  line-height: 1.7;
  margin-bottom: 0.7rem;
}

/* botón responder */

.reply {
  margin-top: 6px;
}

.reply a {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--color-brand);
  opacity: .8;
}

.reply a:hover {
  opacity: 1;
  text-decoration: underline;
}

/* =========================
   RESPUESTAS ANIDADAS
========================= */

.comment-list .children {
  list-style: none;
  margin-top: 1.2rem;
  margin-left: 3.2rem;
  padding-left: 1.2rem;
  border-left: 2px solid #f3f3f3;
}

.comment-list .children .comment {
  border-bottom: none;
  padding-bottom: 1rem;
}

/* =========================
   FORMULARIO
========================= */

.comment-form {
  margin-top: 3rem;
}

/* textarea */

.comment-form textarea {
  width: 100%;
  min-height: 140px;
  padding: 12px 14px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-family: inherit;
  font-size: 0.95rem;
  resize: vertical;
  transition: border-color .2s ease;
}

.comment-form textarea:focus {
  outline: none;
  border-color: var(--color-brand);
}

/* fila de inputs */

.comment-form .comment-form-author,
.comment-form .comment-form-email,
.comment-form .comment-form-url {
  width: 32%;
  display: inline-block;
  vertical-align: top;
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"] {
  width: 100%;
  padding: 9px 10px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-family: inherit;
  font-size: 0.9rem;
  transition: border-color .2s ease;
}

.comment-form input:focus {
  outline: none;
  border-color: var(--color-brand);
}

/* espacio entre campos */

.comment-form .comment-form-author {
  margin-right: 2%;
}

.comment-form .comment-form-email {
  margin-right: 2%;
}

/* checkbox */

.comment-form .comment-form-cookies-consent {
  margin-top: 1rem;
  font-size: 0.85rem;
}

/* botón */

.comment-form input[type="submit"] {
  margin-top: 1.4rem;
  background: transparent;
  border: 2px solid var(--color-brand);
  color: var(--color-brand);
  padding: 10px 18px;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all .25s ease;
}

.comment-form input[type="submit"]:hover {
  background: var(--color-brand);
  color: #fff;
}
