/*
Theme Name: TOSM UX
Theme URI: https://ux.theonsitemanager.com.au
Description: Custom theme matching The Onsite Manager UX site
Version: 1.0
Author: The Onsite Manager
*/

@import url('https://fonts.googleapis.com/css2?family=Raleway:wght@400;600;700;800&display=swap');

:root {
  --brand: #9d2820;
  --brand-dark: #7f1f18;
  --dark: #111;
  --text: #666;
  --heading: #1f2328;
  --bg: #faf7f5;
  --border: #e7e1dc;
  --radius: 18px;
  --radius-sm: 12px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: 'Raleway', sans-serif; color: var(--text); background: #fff; line-height: 1.6; -webkit-font-smoothing: antialiased; }
a { color: var(--brand); text-decoration: none; }
a:hover { color: var(--brand-dark); }
img { max-width: 100%; height: auto; }

.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* Header */
.site-header { background: #fff; padding: 16px 0; position: sticky; top: 0; z-index: 9999; box-shadow: 0 2px 20px rgba(0,0,0,0.08); }
.header-inner { display: flex; align-items: center; justify-content: space-between; max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.logo img { height: 80px; }
.nav { display: flex; align-items: center; gap: 24px; }
.nav a { color: var(--dark); font-weight: 600; font-size: 0.9rem; text-decoration: none; transition: color 0.2s; }
.nav a:hover { color: var(--brand); }
.nav .btn-join { background: var(--brand); color: #fff; padding: 8px 18px; border-radius: 8px; font-weight: 700; }
.nav .btn-join:hover { background: var(--brand-dark); color: #fff; }
.dropdown { position: relative; }
.dropdown-trigger { color: var(--dark); font-weight: 600; font-size: 0.9rem; cursor: pointer; }
.dropdown-menu { display: none; position: absolute; top: 100%; left: 0; background: #fff; border-radius: 12px; box-shadow: 0 10px 40px rgba(0,0,0,0.12); padding: 12px 0; min-width: 200px; z-index: 100; }
.dropdown:hover .dropdown-menu { display: block; }
.dropdown-menu a { display: block; padding: 8px 20px; color: var(--dark); font-size: 0.85rem; }
.dropdown-menu a:hover { background: var(--bg); color: var(--brand); }

/* Content */
.site-content { padding: 60px 0; min-height: 60vh; }
.page-title { font-size: 2rem; font-weight: 800; color: var(--heading); margin-bottom: 32px; }

/* Blog posts */
.posts-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 32px; }
.post-card { background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: 0 4px 20px rgba(0,0,0,0.06); transition: transform 0.2s, box-shadow 0.2s; }
.post-card:hover { transform: translateY(-4px); box-shadow: 0 12px 40px rgba(0,0,0,0.1); }
.post-card .post-thumb { width: 100%; height: 200px; object-fit: cover; }
.post-card .post-body { padding: 20px; }
.post-card .post-title { font-size: 1.1rem; font-weight: 700; color: var(--heading); margin-bottom: 8px; line-height: 1.3; }
.post-card .post-title a { color: var(--heading); }
.post-card .post-title a:hover { color: var(--brand); }
.post-card .post-meta { font-size: 0.8rem; color: #999; margin-bottom: 10px; }
.post-card .post-excerpt { font-size: 0.9rem; color: var(--text); line-height: 1.5; }
.post-card .read-more { display: inline-block; margin-top: 12px; font-weight: 700; font-size: 0.85rem; color: var(--brand); }

/* Single post */
.single-post-content { max-width: 800px; margin: 0 auto; }
.single-post-content .entry-title { font-size: 2.2rem; font-weight: 800; color: var(--heading); margin-bottom: 16px; line-height: 1.2; }
.single-post-content .entry-meta { font-size: 0.85rem; color: #999; margin-bottom: 24px; }
.single-post-content .entry-featured { width: 100%; border-radius: var(--radius); margin-bottom: 32px; }
.single-post-content .entry-body { font-size: 1rem; line-height: 1.8; color: var(--text); }
.single-post-content .entry-body h2, .single-post-content .entry-body h3 { color: var(--heading); margin: 32px 0 16px; }
.single-post-content .entry-body p { margin-bottom: 16px; }
.single-post-content .entry-body img { border-radius: var(--radius-sm); margin: 16px 0; }
.single-post-content .entry-body ul, .single-post-content .entry-body ol { margin: 16px 0 16px 24px; }
.single-post-content .entry-body blockquote { border-left: 4px solid var(--brand); padding: 16px 24px; margin: 24px 0; background: var(--bg); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; }

/* Sidebar */
.content-with-sidebar { display: grid; grid-template-columns: 1fr 320px; gap: 48px; }
.sidebar .widget { background: var(--bg); border-radius: var(--radius-sm); padding: 24px; margin-bottom: 24px; }
.sidebar .widget-title { font-size: 1rem; font-weight: 700; color: var(--heading); margin-bottom: 12px; }
.sidebar .widget ul { list-style: none; }
.sidebar .widget li { padding: 6px 0; border-bottom: 1px solid var(--border); }
.sidebar .widget li:last-child { border-bottom: none; }
.sidebar .widget a { color: var(--text); font-size: 0.9rem; }
.sidebar .widget a:hover { color: var(--brand); }

/* Footer */
.site-footer { background: var(--dark); color: #aaa; padding: 48px 0 24px; }
.footer-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; margin-bottom: 32px; }
.footer-col h4 { color: #fff; font-size: 0.9rem; margin-bottom: 12px; }
.footer-col a { display: block; color: #aaa; font-size: 0.85rem; margin-bottom: 6px; }
.footer-col a:hover { color: #fff; }
.footer-bottom { border-top: 1px solid #333; padding-top: 20px; text-align: center; font-size: 0.8rem; }

/* Pagination */
.pagination { display: flex; justify-content: center; gap: 8px; margin-top: 48px; }
.pagination a, .pagination span { display: inline-block; padding: 8px 14px; border-radius: 8px; font-weight: 600; font-size: 0.9rem; }
.pagination .current { background: var(--brand); color: #fff; }
.pagination a { background: var(--bg); color: var(--text); }
.pagination a:hover { background: var(--brand); color: #fff; }

/* Categories */
.cat-links { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 32px; }
.cat-links a { background: var(--bg); padding: 6px 14px; border-radius: 20px; font-size: 0.8rem; font-weight: 600; color: var(--text); }
.cat-links a:hover, .cat-links a.current { background: var(--brand); color: #fff; }

/* Responsive */
@media (max-width: 768px) {
  .nav { display: none; }
  .posts-grid { grid-template-columns: 1fr; }
  .content-with-sidebar { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .header-inner { padding: 0 16px; }
}
