/*
Theme Name: Apexstay
Theme URI: https://example.com/apexstay
Author: Apexstay
Author URI: https://example.com
Description: A lightweight, secure, SEO-optimized and accessible custom WordPress theme for Apexstay, a premium travel and accommodation booking brand. Zero framework dependencies, mobile-first, and built for speed.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: LICENSE
Text Domain: apexstay
Tags: blog, e-commerce, one-column, two-columns, three-columns, grid-layout, custom-logo, custom-header, custom-menu, featured-images, footer-widgets, sidebar, translation-ready, threaded-comments, accessibility-ready

This theme, like WordPress, is licensed under the GPL.
Use it to make something cool, have fun, and share what you've learned with others.
*/

/* =========================================================
   0. CSS RESET & VARIABLES
   ========================================================= */
:root {
	--apx-navy: #003580;
	--apx-navy-dark: #00204d;
	--apx-blue: #006ce4;
	--apx-blue-light: #eaf3ff;
	--apx-bg: #f5f7fa;
	--apx-white: #ffffff;
	--apx-text: #1a1a1a;
	--apx-text-light: #56606f;
	--apx-border: #dde3ea;
	--apx-success: #0a8f4c;
	--apx-radius: 6px;
	--apx-shadow: 0 2px 10px rgba(0, 32, 77, 0.08);
	--apx-shadow-lg: 0 8px 24px rgba(0, 32, 77, 0.14);
	--apx-font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
	--apx-maxw: 1200px;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
	margin: 0;
	font-family: var(--apx-font);
	background: var(--apx-bg);
	color: var(--apx-text);
	line-height: 1.6;
	font-size: 16px;
	-webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--apx-blue); text-decoration: none; }
a:hover, a:focus { text-decoration: underline; }

h1, h2, h3, h4, h5, h6 {
	font-family: var(--apx-font);
	color: var(--apx-navy);
	line-height: 1.25;
	margin: 0 0 .6em;
	font-weight: 700;
}

h1 { font-size: clamp(1.8rem, 3.5vw, 2.6rem); }
h2 { font-size: clamp(1.5rem, 2.8vw, 2.1rem); }
h3 { font-size: clamp(1.2rem, 2vw, 1.5rem); }

p { margin: 0 0 1.2em; }

ul, ol { padding-left: 1.4em; }

button, input, select, textarea { font-family: inherit; font-size: 1rem; }

.container {
	max-width: var(--apx-maxw);
	margin: 0 auto;
	padding: 0 20px;
}

.screen-reader-text {
	position: absolute !important;
	width: 1px; height: 1px;
	overflow: hidden;
	clip: rect(1px, 1px, 1px, 1px);
	white-space: nowrap;
	border: 0; padding: 0; margin: -1px;
}
.screen-reader-text:focus {
	position: fixed !important;
	top: 10px; left: 10px;
	width: auto; height: auto;
	padding: 12px 18px;
	background: var(--apx-navy);
	color: #fff;
	z-index: 100000;
	clip: auto;
	border-radius: var(--apx-radius);
}

.skip-link {
	position: absolute;
	left: -9999px;
	top: 0;
	background: var(--apx-navy);
	color: #fff;
	padding: 10px 16px;
	z-index: 100000;
	border-radius: 0 0 var(--apx-radius) 0;
}
.skip-link:focus { left: 0; }

/* Buttons */
.btn {
	display: inline-block;
	background: var(--apx-blue);
	color: #fff;
	border: none;
	padding: 12px 24px;
	border-radius: var(--apx-radius);
	font-weight: 600;
	cursor: pointer;
	transition: background .15s ease, transform .1s ease;
}
.btn:hover, .btn:focus { background: var(--apx-navy); color: #fff; text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn-outline {
	background: transparent;
	border: 2px solid #fff;
	color: #fff;
}
.btn-outline:hover { background: rgba(255,255,255,.15); color: #fff; }

/* =========================================================
   1. SITE HEADER
   ========================================================= */
.site-header-top {
	background: var(--apx-navy);
	color: #fff;
	font-size: .85rem;
	padding: 6px 0;
}
.site-header-top .container { display: flex; justify-content: flex-end; gap: 18px; }
.site-header-top a { color: #cfe0ff; }

.site-branding-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 16px;
	padding: 18px 0;
	background: #fff;
	border-bottom: 1px solid var(--apx-border);
}

.site-branding { display: flex; align-items: center; gap: 12px; min-height: 56px; }
.site-branding img.custom-logo { max-height: 64px; width: auto; }

.site-logo-fallback { display: flex; align-items: center; gap: 10px; }
.site-logo-fallback svg { flex-shrink: 0; }
.site-title {
	font-size: 1.7rem;
	font-weight: 800;
	color: var(--apx-navy);
	margin: 0;
	letter-spacing: -.5px;
	line-height: 1;
}
.site-title a { color: var(--apx-navy); }
.site-title a:hover { text-decoration: none; }
.site-description {
	display: block;
	font-size: .72rem;
	font-weight: 600;
	letter-spacing: 1px;
	text-transform: uppercase;
	color: var(--apx-blue);
	margin-top: 2px;
}

/* Primary nav */
.main-navigation { display: flex; align-items: center; }
.main-navigation ul {
	list-style: none;
	display: flex;
	gap: 6px;
	margin: 0;
	padding: 0;
	flex-wrap: wrap;
}
.main-navigation li { position: relative; }
.main-navigation a {
	display: block;
	padding: 10px 14px;
	color: var(--apx-navy);
	font-weight: 600;
	border-radius: var(--apx-radius);
}
.main-navigation a:hover, .main-navigation a:focus {
	background: var(--apx-blue-light);
	text-decoration: none;
	color: var(--apx-navy);
}
.main-navigation ul ul {
	position: absolute;
	top: 100%; left: 0;
	background: #fff;
	box-shadow: var(--apx-shadow-lg);
	flex-direction: column;
	min-width: 200px;
	padding: 8px;
	border-radius: var(--apx-radius);
	display: none;
	z-index: 50;
}
.main-navigation li:hover > ul,
.main-navigation li:focus-within > ul { display: flex; }

.menu-toggle {
	display: none;
	background: var(--apx-navy);
	color: #fff;
	border: none;
	padding: 10px 14px;
	border-radius: var(--apx-radius);
	font-weight: 600;
	cursor: pointer;
}

/* Hero / banner */
.site-hero {
	position: relative;
	background: linear-gradient(135deg, var(--apx-navy) 0%, var(--apx-navy-dark) 100%);
	background-size: cover;
	background-position: center;
	color: #fff;
	padding: 50px 0 70px;
	text-align: center;
}
.site-hero::before {
	content: "";
	position: absolute; inset: 0;
	background: rgba(0, 32, 77, 0.55);
}
.site-hero.has-hero-image::before { background: rgba(0, 32, 77, 0.62); }
.site-hero .hero-inner { position: relative; z-index: 2; }
.site-hero h1 { color: #fff; margin-bottom: .3em; }
.site-hero p.hero-subtitle {
	font-size: 1.1rem;
	color: #dce8ff;
	max-width: 640px;
	margin: 0 auto 1.6em;
}

/* Header booking widget */
.header-booking-widget-area {
	position: relative;
	z-index: 3;
	max-width: 980px;
	margin: 0 auto;
	margin-top: 10px;
	background: #fff;
	border-radius: var(--apx-radius);
	box-shadow: var(--apx-shadow-lg);
	padding: 20px;
	color: var(--apx-text);
	text-align: left;
}
.header-booking-widget-area .widget { margin: 0; }
.header-booking-widget-area .widget-title {
	color: var(--apx-navy);
	font-size: 1rem;
	text-transform: uppercase;
	letter-spacing: .5px;
	margin-bottom: 12px;
}
.header-booking-widget-area .widget + .widget { margin-top: 16px; }
.header-booking-placeholder {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
	gap: 12px;
	align-items: end;
}
.header-booking-placeholder label {
	font-size: .78rem;
	font-weight: 700;
	color: var(--apx-text-light);
	display: block;
	margin-bottom: 4px;
	text-transform: uppercase;
}
.header-booking-placeholder input,
.header-booking-placeholder select {
	width: 100%;
	padding: 10px 12px;
	border: 1px solid var(--apx-border);
	border-radius: var(--apx-radius);
	background: var(--apx-bg);
}
.header-booking-placeholder .btn { width: 100%; padding: 12px; }

/* =========================================================
   2. LAYOUT / CONTENT GRID
   ========================================================= */
.site-main-wrap { padding: 50px 0; }
.content-sidebar-layout {
	display: grid;
	grid-template-columns: 1fr;
	gap: 40px;
}
.has-sidebar .content-sidebar-layout { grid-template-columns: 2.2fr 1fr; }

section.seo-content { margin-bottom: 50px; }
section.seo-content article { max-width: 100%; }
.seo-content h2 { border-bottom: 3px solid var(--apx-blue); display: inline-block; padding-bottom: 6px; }
.destination-grid, .why-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
	gap: 20px;
	margin: 24px 0 0;
	list-style: none;
	padding: 0;
}
.destination-grid li, .why-grid li {
	background: #fff;
	border: 1px solid var(--apx-border);
	border-radius: var(--apx-radius);
	padding: 18px;
	box-shadow: var(--apx-shadow);
}
.destination-grid li strong, .why-grid li strong { color: var(--apx-navy); display: block; margin-bottom: 4px; }

/* Recent posts grid */
.recent-posts h2 { margin-bottom: 24px; }
.posts-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 26px;
}
.post-card {
	background: #fff;
	border-radius: var(--apx-radius);
	overflow: hidden;
	box-shadow: var(--apx-shadow);
	display: flex;
	flex-direction: column;
	transition: transform .15s ease, box-shadow .15s ease;
}
.post-card:hover { transform: translateY(-4px); box-shadow: var(--apx-shadow-lg); }
.post-card .post-thumb { aspect-ratio: 16/10; overflow: hidden; background: var(--apx-blue-light); }
.post-card .post-thumb img { width: 100%; height: 100%; object-fit: cover; }
.post-card .post-body { padding: 18px; display: flex; flex-direction: column; flex: 1; }
.post-card .post-date { font-size: .78rem; color: var(--apx-text-light); text-transform: uppercase; letter-spacing: .5px; margin-bottom: 6px; }
.post-card h3 { font-size: 1.15rem; margin-bottom: 8px; }
.post-card h3 a { color: var(--apx-navy); }
.post-card h3 a:hover { text-decoration: none; color: var(--apx-blue); }
.post-card p.excerpt { color: var(--apx-text-light); font-size: .92rem; flex: 1; }
.post-card .read-more { font-weight: 700; font-size: .88rem; align-self: flex-start; }

/* Blog listing (index.php) */
.blog-post { background: #fff; border-radius: var(--apx-radius); box-shadow: var(--apx-shadow); padding: 26px; margin-bottom: 26px; }
.blog-post .entry-meta { font-size: .82rem; color: var(--apx-text-light); margin-bottom: 8px; text-transform: uppercase; letter-spacing: .5px; }
.blog-post .entry-thumb { margin: -26px -26px 20px; border-radius: var(--apx-radius) var(--apx-radius) 0 0; overflow: hidden; }
.pagination { margin-top: 30px; display: flex; gap: 10px; flex-wrap: wrap; }
.pagination a, .pagination span { padding: 8px 14px; background: #fff; border: 1px solid var(--apx-border); border-radius: var(--apx-radius); }
.pagination .current { background: var(--apx-navy); color: #fff; border-color: var(--apx-navy); }

/* =========================================================
   3. SIDEBAR
   ========================================================= */
.widget-area .widget {
	background: #fff;
	border-radius: var(--apx-radius);
	box-shadow: var(--apx-shadow);
	padding: 20px;
	margin-bottom: 24px;
}
.widget-area .widget-title {
	font-size: 1rem;
	text-transform: uppercase;
	letter-spacing: .5px;
	color: var(--apx-navy);
	border-bottom: 2px solid var(--apx-blue-light);
	padding-bottom: 10px;
	margin-bottom: 14px;
}
.widget-area ul { list-style: none; padding: 0; margin: 0; }
.widget-area ul li { padding: 6px 0; border-bottom: 1px dashed var(--apx-border); }
.widget-area ul li:last-child { border-bottom: none; }

/* =========================================================
   4. FOOTER
   ========================================================= */
.site-footer { background: var(--apx-navy-dark); color: #cfe0ff; margin-top: 60px; }
.footer-widgets {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 30px;
	padding: 50px 0;
}
.footer-widgets .widget-title {
	color: #fff;
	font-size: 1rem;
	text-transform: uppercase;
	letter-spacing: .5px;
	margin-bottom: 16px;
}
.footer-widgets .widget a { color: #b8cdf0; }
.footer-widgets .widget a:hover { color: #fff; }
.footer-widgets ul { list-style: none; padding: 0; margin: 0; }
.footer-widgets ul li { padding: 5px 0; }
.site-footer-bottom {
	border-top: 1px solid rgba(255,255,255,.12);
	padding: 18px 0;
	text-align: center;
	font-size: .85rem;
	color: #9db8e0;
}
.site-footer-bottom a { color: #cfe0ff; }

/* =========================================================
   5. COMMENTS
   ========================================================= */
.comments-area { margin-top: 40px; background: #fff; padding: 24px; border-radius: var(--apx-radius); box-shadow: var(--apx-shadow); }
.comment-list { list-style: none; margin: 0; padding: 0; }
.comment-list li { padding: 16px 0; border-bottom: 1px solid var(--apx-border); }
.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
	width: 100%;
	padding: 10px 12px;
	border: 1px solid var(--apx-border);
	border-radius: var(--apx-radius);
	margin-bottom: 14px;
	background: var(--apx-bg);
}
.apx-hp-field { position: absolute !important; left: -9999px !important; top: -9999px !important; }

/* =========================================================
   6. RESPONSIVE
   ========================================================= */
@media (max-width: 900px) {
	.posts-grid { grid-template-columns: repeat(2, 1fr); }
	.has-sidebar .content-sidebar-layout { grid-template-columns: 1fr; }
	.footer-widgets { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 700px) {
	.main-navigation { display: none; width: 100%; }
	.main-navigation.is-open { display: block; }
	.main-navigation ul { flex-direction: column; }
	.main-navigation ul ul { position: static; box-shadow: none; display: none; padding-left: 14px; }
	.main-navigation li.menu-item-open > ul { display: flex; }
	.menu-toggle { display: inline-block; }
	.site-branding-row { flex-direction: column; align-items: flex-start; }
	.posts-grid { grid-template-columns: 1fr; }
	.footer-widgets { grid-template-columns: 1fr; }
	.header-booking-placeholder { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 480px) {
	.header-booking-placeholder { grid-template-columns: 1fr; }
	.site-hero { padding: 34px 0 50px; }
}

@media print {
	.site-header-top, .main-navigation, .site-footer, .header-booking-widget-area, .widget-area { display: none; }
}
