/*
Theme Name: APREV Events
Theme URI: https://aprev.xyz
Author: aprev
Description: Custom fast and clean theme for aprev.xyz - the global events and tickets directory. Works with the APREVENTS plugin shortcodes and includes a ready-made front page.
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: aprev
Tags: events, blog, news, one-column, custom-menu, custom-logo, featured-images, translation-ready
*/

/* ------------------------------------------------------------
   1. DESIGN TOKENS
------------------------------------------------------------ */
:root {
  --aprev-navy: #0f172a;
  --aprev-navy-2: #1e293b;
  --aprev-blue: #2563eb;
  --aprev-blue-dark: #1d4ed8;
  --aprev-bg: #f8fafc;
  --aprev-card: #ffffff;
  --aprev-text: #334155;
  --aprev-heading: #0f172a;
  --aprev-muted: #64748b;
  --aprev-border: #e2e8f0;
  --aprev-accent: #f59e0b;
  --aprev-radius: 12px;
  --aprev-radius-sm: 8px;
  --aprev-shadow: 0 4px 16px rgba(15, 23, 42, .08);
  --aprev-shadow-lg: 0 12px 32px rgba(15, 23, 42, .12);
  --aprev-font: "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* ------------------------------------------------------------
   2. RESET / BASE
------------------------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--aprev-font);
  font-size: 16px;
  line-height: 1.7;
  color: var(--aprev-text);
  background: var(--aprev-bg);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; }
a { color: var(--aprev-blue); text-decoration: none; transition: color .2s ease; }
a:hover { color: var(--aprev-blue-dark); }
h1, h2, h3, h4, h5, h6 { color: var(--aprev-heading); line-height: 1.25; margin: 0 0 .6em; }
h1 { font-size: 2.2rem; }
h2 { font-size: 1.75rem; }
h3 { font-size: 1.35rem; }
p { margin: 0 0 1.1em; }
ul, ol { padding-left: 1.4em; margin: 0 0 1.2em; }
table { width: 100%; border-collapse: collapse; margin: 0 0 1.2em; }
th, td { border: 1px solid var(--aprev-border); padding: .55em .8em; text-align: left; }
th { background: #f1f5f9; }
pre, code { background: #f1f5f9; border-radius: 6px; }
code { padding: .15em .4em; font-size: .92em; }
pre { padding: 1em; overflow-x: auto; }
blockquote { border-left: 4px solid var(--aprev-blue); margin: 0 0 1.2em; padding: .4em 1em; background: #eff6ff; color: var(--aprev-heading); }
input[type="text"], input[type="email"], input[type="search"], textarea, select {
  width: 100%; padding: .65em .9em; border: 1px solid var(--aprev-border);
  border-radius: var(--aprev-radius-sm); font: inherit; background: #fff; color: var(--aprev-text);
}
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px,1px,1px,1px); }

/* ------------------------------------------------------------
   3. LAYOUT
------------------------------------------------------------ */
.aprev-container { max-width: 1160px; margin: 0 auto; padding: 0 20px; }
.aprev-section { padding: 56px 0; }
.aprev-section h2 { font-size: 1.7rem; }
.aprev-section-sub { color: var(--aprev-muted); max-width: 640px; }

/* ------------------------------------------------------------
   4. HEADER / NAV
------------------------------------------------------------ */
.aprev-header { background: #fff; border-bottom: 1px solid var(--aprev-border); position: sticky; top: 0; z-index: 100; }
.aprev-header-inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; min-height: 68px; }
.aprev-brand { display: flex; align-items: center; gap: 10px; font-size: 1.35rem; font-weight: 800; color: var(--aprev-navy); letter-spacing: -.02em; }
.aprev-brand img { max-height: 44px; width: auto; }
.aprev-brand:hover { color: var(--aprev-navy); }
.aprev-brand .aprev-dot { color: var(--aprev-blue); }
.aprev-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 26px; }
.aprev-nav a { color: var(--aprev-text); font-weight: 600; font-size: .95rem; }
.aprev-nav a:hover, .aprev-nav .current-menu-item > a { color: var(--aprev-blue); }
.aprev-nav-toggle { display: none; background: none; border: 0; cursor: pointer; padding: 8px; }
.aprev-nav-toggle .bar { display: block; width: 24px; height: 2.5px; background: var(--aprev-navy); margin: 5px 0; border-radius: 2px; }
@media (max-width: 860px) {
  .aprev-nav-toggle { display: block; }
  .aprev-nav { display: none; position: absolute; top: 100%; left: 0; right: 0; background: #fff; border-bottom: 1px solid var(--aprev-border); box-shadow: var(--aprev-shadow); }
  .aprev-nav.open { display: block; }
  .aprev-nav ul { flex-direction: column; gap: 0; padding: 12px 20px; }
  .aprev-nav li { border-bottom: 1px solid #f1f5f9; }
  .aprev-nav a { display: block; padding: 12px 0; }
  .aprev-nav li:last-child { border-bottom: 0; }
}

/* ------------------------------------------------------------
   5. HERO
------------------------------------------------------------ */
.aprev-hero { background: linear-gradient(135deg, #0f172a 0%, #1e3a8a 55%, #2563eb 100%); color: #fff; padding: 84px 0; }
.aprev-hero-inner { max-width: 760px; }
.aprev-hero h1 { color: #fff; font-size: 2.6rem; margin-bottom: .4em; }
.aprev-hero p { color: #cbd5e1; font-size: 1.15rem; margin-bottom: 1.6em; }
.aprev-hero-badge { display: inline-block; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.25); color: #fff; font-size: .8rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; padding: .35em .9em; border-radius: 999px; margin-bottom: 1.2em; }
.aprev-btn { display: inline-block; background: var(--aprev-blue); color: #fff; font-weight: 700; padding: .8em 1.8em; border-radius: var(--aprev-radius-sm); border: 0; cursor: pointer; transition: background .2s ease, transform .2s ease; }
.aprev-btn:hover { background: var(--aprev-blue-dark); color: #fff; transform: translateY(-1px); }
.aprev-btn-light { background: #fff; color: var(--aprev-navy); }
.aprev-btn-light:hover { background: #e2e8f0; color: var(--aprev-navy); }
.aprev-btn-ghost { background: transparent; color: #fff; border: 1.5px solid rgba(255,255,255,.5); }
.aprev-btn-ghost:hover { border-color: #fff; color: #fff; }
.aprev-hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }

/* ------------------------------------------------------------
   6. SECTIONS / CARDS
------------------------------------------------------------ */
.aprev-section-title { font-size: 1.7rem; margin-bottom: 8px; }
.aprev-section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 28px; flex-wrap: wrap; }
.aprev-section-head .aprev-link { font-weight: 700; font-size: .92rem; }

.aprev-posts-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.aprev-post-card { background: var(--aprev-card); border: 1px solid var(--aprev-border); border-radius: var(--aprev-radius); overflow: hidden; display: flex; flex-direction: column; transition: transform .2s ease, box-shadow .2s ease; }
.aprev-post-card:hover { transform: translateY(-4px); box-shadow: var(--aprev-shadow-lg); }
.aprev-post-card .aprev-post-thumb { display: block; aspect-ratio: 16 / 9; overflow: hidden; background: #e2e8f0; }
.aprev-post-card .aprev-post-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s ease; }
.aprev-post-card:hover .aprev-post-thumb img { transform: scale(1.04); }
.aprev-post-card-body { padding: 20px; display: flex; flex-direction: column; flex: 1; }
.aprev-post-card h3 { font-size: 1.05rem; margin: 0 0 10px; }
.aprev-post-card h3 a { color: var(--aprev-heading); }
.aprev-post-card h3 a:hover { color: var(--aprev-blue); }
.aprev-post-card .aprev-post-excerpt { color: var(--aprev-muted); font-size: .92rem; flex: 1; }
.aprev-post-meta { color: var(--aprev-muted); font-size: .8rem; margin-top: 14px; }
.aprev-post-meta a { color: var(--aprev-muted); }
.aprev-post-meta a:hover { color: var(--aprev-blue); }

/* ------------------------------------------------------------
   7. BLOG / SINGLE / PAGES
------------------------------------------------------------ */
.aprev-page-title { background: var(--aprev-navy); color: #fff; padding: 56px 0; }
.aprev-page-title h1 { color: #fff; margin: 0; }
.aprev-page-title .aprev-crumb { color: #94a3b8; font-size: .85rem; margin-top: 8px; }

.aprev-content { background: var(--aprev-card); border: 1px solid var(--aprev-border); border-radius: var(--aprev-radius); padding: 40px; }
.aprev-content h2 { margin-top: 1.4em; }
.aprev-article-meta { color: var(--aprev-muted); font-size: .9rem; margin-bottom: 24px; }
.aprev-article-thumb { border-radius: var(--aprev-radius); margin-bottom: 28px; width: 100%; }
.aprev-post-nav { display: flex; justify-content: space-between; gap: 20px; margin-top: 40px; padding-top: 24px; border-top: 1px solid var(--aprev-border); font-size: .9rem; }
.aprev-tags { margin-top: 24px; }
.aprev-tag { display: inline-block; background: #eff6ff; color: var(--aprev-blue); border-radius: 999px; padding: .25em .8em; font-size: .8rem; font-weight: 600; margin: 0 6px 6px 0; }
.aprev-tag:hover { background: #dbeafe; color: var(--aprev-blue-dark); }

/* ------------------------------------------------------------
   8. CTA STRIP
------------------------------------------------------------ */
.aprev-cta { background: linear-gradient(120deg, #1e3a8a, #2563eb); color: #fff; padding: 44px 0; text-align: center; }
.aprev-cta h2 { color: #fff; margin-bottom: 8px; }
.aprev-cta p { color: #dbeafe; margin-bottom: 20px; }

/* ------------------------------------------------------------
   9. FOOTER
------------------------------------------------------------ */
.aprev-footer { background: var(--aprev-navy); color: #94a3b8; padding: 56px 0 0; margin-top: 0; }
.aprev-footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 36px; padding-bottom: 36px; }
.aprev-footer h4 { color: #fff; font-size: .95rem; margin-bottom: 14px; }
.aprev-footer ul { list-style: none; padding: 0; margin: 0; }
.aprev-footer li { margin-bottom: 8px; }
.aprev-footer a { color: #94a3b8; font-size: .9rem; }
.aprev-footer a:hover { color: #fff; }
.aprev-footer .aprev-footer-brand { font-size: 1.25rem; font-weight: 800; color: #fff; }
.aprev-footer .aprev-footer-about { font-size: .9rem; }
.aprev-footer-bottom { border-top: 1px solid #1e293b; padding: 18px 0; font-size: .82rem; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
@media (max-width: 860px) {
  .aprev-footer-grid { grid-template-columns: 1fr 1fr; }
  .aprev-posts-grid { grid-template-columns: 1fr; }
  .aprev-hero h1 { font-size: 2rem; }
  .aprev-content { padding: 24px; }
}

/* ------------------------------------------------------------
   10. UTILITIES / RESPONSIVE
------------------------------------------------------------ */
@media (max-width: 1024px) {
  .aprev-posts-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .aprev-posts-grid { grid-template-columns: 1fr; }
  .aprev-section { padding: 40px 0; }
  h1 { font-size: 1.8rem; }
}
.aprev-aligncenter { display: block; margin-left: auto; margin-right: auto; }
.aprev-searchform { display: flex; gap: 10px; max-width: 480px; }
.aprev-searchform input[type="submit"] { background: var(--aprev-blue); color: #fff; border: 0; border-radius: var(--aprev-radius-sm); padding: .65em 1.4em; font-weight: 700; cursor: pointer; }
.aprev-404 { text-align: center; padding: 80px 0; }
.aprev-404 .aprev-404-code { font-size: 5rem; font-weight: 800; color: #dbeafe; line-height: 1; }
