/*
Theme Name: iFOVS Liquid Glass
Theme URI: https://ifovs.net/
Author: iFOVS Business Support Services
Description: Custom WordPress theme for iFOVS Business Support Services — a deep-midnight, liquid-glass design system with editable pages, native posts and full SEO-plugin support.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: ifovs
Tags: business, one-column, custom-menu, custom-logo, featured-images, translation-ready
*/

/*
  The full design system lives in assets/css/style.css and is enqueued by
  functions.php. This file exists so WordPress can identify the theme, and
  holds only the styles that WordPress itself injects into pages.
*/

/* ---------- WordPress core classes ---------- */
.alignleft {
  float: left;
  margin: 0.4rem 1.6rem 1.2rem 0;
}

.alignright {
  float: right;
  margin: 0.4rem 0 1.2rem 1.6rem;
}

.aligncenter {
  display: block;
  margin-inline: auto;
}

.alignwide,
.alignfull {
  max-width: 100%;
}

.wp-caption { max-width: 100%; }

.wp-caption-text,
.wp-element-caption,
figcaption {
  font-size: 0.82rem;
  color: var(--text-dim);
  text-align: center;
  margin-top: 0.6rem;
}

.screen-reader-text {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.screen-reader-text:focus {
  position: static !important;
  width: auto;
  height: auto;
  clip: auto;
  white-space: normal;
}

.sticky .post-card { border-color: rgba(53, 226, 240, 0.4); }

/* ---------- Editor blocks inside .article / .prose ---------- */
.article .wp-block-image,
.prose .wp-block-image { margin-block: 1.8rem; }

.article .wp-block-image img,
.prose .wp-block-image img { border-radius: var(--r-md); }

.article .wp-block-quote,
.prose .wp-block-quote {
  border-left: 2px solid var(--accent-1);
  padding-left: 1.3rem;
  margin-block: 1.6rem;
  color: var(--text-mid);
}

.article .wp-block-button__link,
.prose .wp-block-button__link {
  display: inline-flex;
  align-items: center;
  padding: 0.85rem 1.7rem;
  border-radius: var(--r-pill);
  background: var(--grad-accent);
  color: #05101f;
  font-weight: 600;
  text-decoration: none;
  box-shadow: var(--sh-glow);
}

.article .wp-block-table,
.prose .wp-block-table { overflow-x: auto; }

.article table,
.prose table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
}

.article th,
.article td,
.prose th,
.prose td {
  padding: 0.7rem 0.9rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  text-align: left;
}

.article th,
.prose th { color: var(--text-hi); background: rgba(255, 255, 255, 0.05); }

.article code,
.prose code {
  padding: 0.15em 0.4em;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.08);
  font-size: 0.9em;
}

.article pre,
.prose pre {
  padding: 1.1rem 1.3rem;
  border-radius: var(--r-sm);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--glass-brd);
  overflow-x: auto;
  margin-block: 1.4rem;
}

/* ---------- WordPress gallery block → our photo grid ---------- */
.wp-block-gallery.has-nested-images {
  display: grid !important;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr));
  gap: 1rem;
}

.wp-block-gallery.has-nested-images figure.wp-block-image {
  position: relative;
  width: 100% !important;
  margin: 0 !important;
  aspect-ratio: 4 / 3;
  border-radius: var(--r-md);
  overflow: hidden;
  border: 1px solid var(--glass-brd);
  cursor: pointer;
  transition: transform var(--t-med), box-shadow var(--t-med), border-color var(--t-med);
}

.wp-block-gallery.has-nested-images figure.wp-block-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 0;
  transition: transform var(--t-slow);
}

.wp-block-gallery.has-nested-images figure.wp-block-image:hover {
  transform: translateY(-5px);
  border-color: var(--glass-brd-hi);
  box-shadow: var(--sh-3);
}

.wp-block-gallery.has-nested-images figure.wp-block-image:hover img { transform: scale(1.07); }

.wp-block-gallery.has-nested-images figure.wp-block-image figcaption { display: none; }

/* ---------- Comments ---------- */
.comment-list { display: grid; gap: 1.2rem; }
.comment-list .children { margin-top: 1.2rem; margin-left: 1.6rem; display: grid; gap: 1.2rem; }

.comment-body {
  padding: 1.3rem 1.5rem;
  border-radius: var(--r-md);
  background: var(--glass-bg);
  border: 1px solid var(--glass-brd);
}

.comment-author { color: var(--text-hi); font-weight: 600; font-size: 0.95rem; }
.comment-author img { border-radius: 50%; margin-right: 0.6rem; vertical-align: middle; }
.comment-metadata { font-size: 0.78rem; color: var(--text-dim); margin-bottom: 0.7rem; }
.comment-content p { font-size: 0.94rem; color: var(--text-lo); }
.comment-reply-link { font-size: 0.85rem; color: var(--accent-2); font-weight: 600; }

/* ---------- Pagination ---------- */
.pagination {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: clamp(2.5rem, 5vw, 3.5rem);
}

.pagination .page-numbers {
  display: grid;
  place-items: center;
  min-width: 42px;
  height: 42px;
  padding-inline: 0.85rem;
  border-radius: var(--r-pill);
  background: var(--glass-bg);
  border: 1px solid var(--glass-brd);
  color: var(--text-lo);
  font-size: 0.9rem;
  font-weight: 500;
  transition: background var(--t-fast), color var(--t-fast), border-color var(--t-fast);
}

.pagination .page-numbers:hover {
  color: var(--text-hi);
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--glass-brd-hi);
}

.pagination .page-numbers.current {
  background: var(--grad-accent);
  border-color: transparent;
  color: #05101f;
  font-weight: 700;
  box-shadow: var(--sh-glow);
}

/* ---------- Admin bar offset ---------- */
body.admin-bar .nav { top: 32px; }
body.admin-bar .drawer { inset: calc(var(--nav-h) + 32px) 0 0 0; }

@media screen and (max-width: 782px) {
  body.admin-bar .nav { top: 46px; }
  body.admin-bar .drawer { inset: calc(var(--nav-h) + 46px) 0 0 0; }
}
