/*
Theme Name: RentYieldAI
Theme URI: https://rentyieldai.com/
Author: RentYieldAI
Author URI: https://rentyieldai.com/
Description: A lightweight, accessible WordPress theme for UK rental-yield, Buy-to-Let and property-investment publishers.
Version: 1.5.0
Requires at least: 6.3
Tested up to: 6.6
Requires PHP: 7.4
License: GPL-2.0-or-later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: rentyieldai
Tags: blog, grid-layout, one-column, two-columns, custom-logo, featured-images
*/

:root {
  --ry-navy: #0b1f3a;
  --ry-ink: #14213d;
  --ry-blue: #2f6fed;
  --ry-blue-dark: #1f4fb5;
  --ry-mint: #d9f6ec;
  --ry-green: #0c8b67;
  --ry-sand: #f5f7fb;
  --ry-line: #dce4f0;
  --ry-muted: #5c6b82;
  --ry-white: #fff;
  --ry-shadow: 0 18px 50px rgba(18, 44, 85, 0.11);
  --ry-radius: 18px;
  --ry-max: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ry-ink);
  background: var(--ry-white);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 17px;
  line-height: 1.65;
}

a { color: var(--ry-blue-dark); text-decoration-thickness: .08em; text-underline-offset: .15em; }
a:hover { color: var(--ry-blue); }
img { display: block; max-width: 100%; height: auto; }
button, input, select, textarea { font: inherit; }

.screen-reader-text {
  clip: rect(1px, 1px, 1px, 1px); clip-path: inset(50%); height: 1px; width: 1px;
  margin: -1px; overflow: hidden; padding: 0; position: absolute !important; word-wrap: normal !important;
}
.screen-reader-text:focus {
  background: #fff; clip: auto !important; clip-path: none; color: #000; display: block;
  height: auto; left: 5px; padding: 12px 16px; top: 5px; width: auto; z-index: 100000;
}

.wrap { width: min(calc(100% - 40px), var(--ry-max)); margin-inline: auto; }
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.95); border-bottom: 1px solid var(--ry-line); backdrop-filter: blur(12px); }
.header-inner { min-height: 76px; display: flex; align-items: center; justify-content: space-between; gap: 28px; }
.site-branding { display: flex; align-items: center; gap: 12px; min-width: 220px; }
.custom-logo-link { display: block; }
.custom-logo { max-height: 44px; width: auto; }
.site-title { color: var(--ry-navy); font-size: 1.12rem; font-weight: 800; letter-spacing: -.02em; line-height: 1.1; text-decoration: none; }
.site-description { color: var(--ry-muted); font-size: .72rem; line-height: 1.2; margin: 3px 0 0; }
.primary-menu { display: flex; align-items: center; gap: 22px; list-style: none; margin: 0; padding: 0; }
.primary-menu a { color: var(--ry-ink); font-size: .91rem; font-weight: 650; text-decoration: none; }
.primary-menu a:hover { color: var(--ry-blue); }
.menu-toggle { display: none; border: 1px solid var(--ry-line); border-radius: 9px; background: #fff; color: var(--ry-navy); padding: 8px 12px; cursor: pointer; }

.hero { background: radial-gradient(circle at 85% 10%, #d7e8ff 0, transparent 36%), linear-gradient(135deg, #f5f9ff 0%, #eaf6f1 100%); padding: 82px 0 76px; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(320px, .9fr); gap: 60px; align-items: center; }
.eyebrow { color: var(--ry-green); font-size: .76rem; font-weight: 800; letter-spacing: .12em; margin: 0 0 14px; text-transform: uppercase; }
h1, h2, h3, h4 { color: var(--ry-navy); font-weight: 800; letter-spacing: -.035em; line-height: 1.16; margin: 0 0 18px; }
h1 { font-size: clamp(2.4rem, 5vw, 4.7rem); max-width: 760px; }
h2 { font-size: clamp(1.8rem, 3vw, 2.65rem); }
h3 { font-size: 1.3rem; }
.hero-copy { color: #3f506a; font-size: 1.12rem; max-width: 660px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 13px; margin-top: 28px; }
.button, .wp-block-button__link { display: inline-flex; align-items: center; justify-content: center; border: 1px solid transparent; border-radius: 10px; cursor: pointer; font-size: .94rem; font-weight: 750; line-height: 1.2; min-height: 48px; padding: 13px 20px; text-decoration: none; transition: transform .2s ease, background .2s ease, box-shadow .2s ease; }
.button:hover, .wp-block-button__link:hover { transform: translateY(-2px); }
.button-primary { background: var(--ry-blue); box-shadow: 0 10px 22px rgba(47,111,237,.24); color: #fff; }
.button-primary:hover { background: var(--ry-blue-dark); color: #fff; }
.button-secondary { background: #fff; border-color: var(--ry-line); color: var(--ry-navy); }
.button-secondary:hover { background: var(--ry-sand); color: var(--ry-navy); }
.hero-proof { display: flex; flex-wrap: wrap; gap: 14px 22px; color: var(--ry-muted); font-size: .85rem; margin-top: 25px; }
.hero-proof span::before { color: var(--ry-green); content: "✓"; font-weight: 900; margin-right: 6px; }
.hero-card { background: rgba(255,255,255,.84); border: 1px solid rgba(207,221,241,.9); border-radius: var(--ry-radius); box-shadow: var(--ry-shadow); padding: 24px; }
.hero-card-top { align-items: center; display: flex; justify-content: space-between; margin-bottom: 14px; }
.hero-card-label { color: var(--ry-muted); font-size: .77rem; font-weight: 750; letter-spacing: .04em; text-transform: uppercase; }
.score { align-items: center; background: var(--ry-mint); border-radius: 999px; color: var(--ry-green); display: inline-flex; font-size: .8rem; font-weight: 800; gap: 4px; padding: 7px 10px; }
.metric-row { align-items: end; border-bottom: 1px solid var(--ry-line); display: flex; justify-content: space-between; padding: 14px 0; }
.metric-row:last-child { border-bottom: 0; padding-bottom: 0; }
.metric-name { color: var(--ry-muted); font-size: .88rem; }
.metric-value { color: var(--ry-navy); font-size: 1.4rem; font-weight: 800; }

.section { padding: 78px 0; }
.section-sand { background: var(--ry-sand); }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 30px; margin-bottom: 30px; }
.section-heading p { color: var(--ry-muted); margin: 0; max-width: 580px; }
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.card { background: #fff; border: 1px solid var(--ry-line); border-radius: var(--ry-radius); padding: 26px; box-shadow: 0 10px 35px rgba(18,44,85,.05); }
.card-icon { align-items: center; background: #edf3ff; border-radius: 12px; color: var(--ry-blue); display: inline-flex; font-size: 1.25rem; height: 42px; justify-content: center; margin-bottom: 17px; width: 42px; }
.card p { color: var(--ry-muted); font-size: .95rem; margin: 0; }
.card a { display: inline-block; font-size: .9rem; font-weight: 750; margin-top: 17px; }
.tool-section { background: var(--ry-navy); color: #fff; }
.tool-section h2, .tool-section h3 { color: #fff; }
.tool-section p { color: #c5d0e3; }
.tool-grid { align-items: center; display: grid; grid-template-columns: .84fr 1.16fr; gap: 50px; }
.tool-points { display: grid; gap: 14px; list-style: none; margin: 26px 0 0; padding: 0; }
.tool-points li { color: #dfe7f5; padding-left: 26px; position: relative; }
.tool-points li::before { color: #75e1be; content: "✓"; font-weight: 900; left: 0; position: absolute; }
.tool-link-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.tool-link-card { background: #fff; border: 1px solid var(--ry-line); border-radius: var(--ry-radius); box-shadow: 0 10px 35px rgba(18,44,85,.05); display: block; min-height: 220px; padding: 24px; position: relative; text-decoration: none; transition: transform .2s ease, box-shadow .2s ease; }
.tool-link-card:hover { box-shadow: var(--ry-shadow); color: var(--ry-ink); transform: translateY(-3px); }
.tool-link-number { color: var(--ry-green); display: block; font-size: .75rem; font-weight: 850; letter-spacing: .1em; margin-bottom: 22px; }
.tool-link-card h3 { color: var(--ry-navy); font-size: 1.15rem; margin-bottom: 9px; }
.tool-link-card p { color: var(--ry-muted); font-size: .9rem; margin: 0; max-width: 290px; }
.tool-link-arrow { bottom: 20px; color: var(--ry-blue); font-size: 1.25rem; font-weight: 800; position: absolute; right: 22px; }

.post-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.post-card { border: 1px solid var(--ry-line); border-radius: var(--ry-radius); overflow: hidden; background: #fff; }
.post-card-image { aspect-ratio: 16 / 9; background: #eaf0f8; overflow: hidden; }
.post-card-image img { height: 100%; object-fit: cover; width: 100%; }
.post-card-body { padding: 22px; }
.post-meta { color: var(--ry-muted); font-size: .76rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; }
.post-card h3 { font-size: 1.18rem; margin: 9px 0 10px; }
.post-card h3 a { color: var(--ry-navy); text-decoration: none; }
.post-card p { color: var(--ry-muted); font-size: .91rem; margin: 0; }

.cta { background: linear-gradient(115deg, var(--ry-blue), #6a55d9); border-radius: var(--ry-radius); color: #fff; padding: 38px 44px; }
.cta h2 { color: #fff; max-width: 680px; }
.cta p { color: #e7ecff; max-width: 670px; }
.cta .button-secondary { border-color: rgba(255,255,255,.35); }

.site-main { min-height: 55vh; }
.page-header { background: var(--ry-sand); border-bottom: 1px solid var(--ry-line); padding: 58px 0; }
.page-header p { color: var(--ry-muted); margin: 0; max-width: 700px; }
.content-area { padding: 58px 0 82px; }
.content-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 52px; }
.entry { min-width: 0; }
.entry-header { margin-bottom: 28px; }
.entry-title { font-size: clamp(2rem, 4vw, 3.45rem); }
.entry-meta { color: var(--ry-muted); font-size: .84rem; }
.entry-content { font-size: 1.06rem; }
.entry-content > * { max-width: 780px; }
.entry-content h2, .entry-content h3, .entry-content h4 { margin-top: 36px; }
.entry-content ul, .entry-content ol { padding-left: 1.25em; }
.entry-content blockquote { border-left: 4px solid var(--ry-blue); color: var(--ry-muted); margin-left: 0; padding: 8px 24px; }
.entry-content table { border-collapse: collapse; font-size: .92rem; width: 100%; }
.entry-content th, .entry-content td { border: 1px solid var(--ry-line); padding: 10px 12px; text-align: left; }
.post-thumbnail { border-radius: var(--ry-radius); margin-bottom: 30px; overflow: hidden; }
.sidebar { min-width: 0; }
.widget { border: 1px solid var(--ry-line); border-radius: 15px; margin-bottom: 20px; padding: 22px; }
.widget-title { font-size: 1rem; margin-bottom: 12px; }
.widget ul { list-style: none; margin: 0; padding: 0; }
.widget li { border-bottom: 1px solid var(--ry-line); font-size: .9rem; padding: 9px 0; }
.widget li:last-child { border-bottom: 0; }

.archive-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.pagination { margin-top: 38px; }
.pagination .nav-links { display: flex; flex-wrap: wrap; gap: 8px; }
.pagination a, .pagination span { border: 1px solid var(--ry-line); border-radius: 8px; padding: 8px 12px; text-decoration: none; }
.pagination .current { background: var(--ry-blue); border-color: var(--ry-blue); color: #fff; }
.search-form { display: flex; gap: 8px; max-width: 560px; }
.search-form label { flex: 1; }
.search-field { border: 1px solid var(--ry-line); border-radius: 9px; min-height: 46px; padding: 10px 13px; width: 100%; }
.search-submit { background: var(--ry-blue); border: 0; border-radius: 9px; color: #fff; cursor: pointer; font-weight: 750; padding: 10px 18px; }

.site-footer { background: #07172d; color: #b8c6da; padding: 52px 0 24px; }
.footer-grid { display: grid; grid-template-columns: 1.2fr .8fr .8fr; gap: 45px; }
.site-footer h2, .site-footer h3 { color: #fff; font-size: 1rem; }
.site-footer a { color: #d7e4f7; }
.site-footer p { font-size: .9rem; margin-top: 0; }
.footer-menu { list-style: none; margin: 0; padding: 0; }
.footer-menu li { margin: 6px 0; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.12); font-size: .78rem; margin-top: 38px; padding-top: 19px; }
.footer-legal { display: flex; flex-wrap: wrap; gap: 12px 18px; margin-bottom: 14px; }
.footer-legal a { font-size: .78rem; text-underline-offset: .15em; }

@media (max-width: 900px) {
  .hero-grid, .tool-grid { grid-template-columns: 1fr; }
  .hero { padding-top: 60px; }
  .cards, .post-grid, .tool-link-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .content-layout { grid-template-columns: 1fr; }
  .sidebar { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
  .widget { margin-bottom: 0; }
}
@media (max-width: 680px) {
  .wrap { width: min(calc(100% - 28px), var(--ry-max)); }
  .header-inner { min-height: 66px; }
  .site-description { display: none; }
  .menu-toggle { display: block; }
  .primary-navigation { display: none; position: absolute; top: 66px; left: 0; right: 0; background: #fff; border-bottom: 1px solid var(--ry-line); padding: 13px 14px; }
  .primary-navigation.is-open { display: block; }
  .primary-menu { align-items: stretch; flex-direction: column; gap: 0; }
  .primary-menu li { border-bottom: 1px solid var(--ry-line); }
  .primary-menu li:last-child { border-bottom: 0; }
  .primary-menu a { display: block; padding: 10px 3px; }
  .hero { padding: 54px 0 58px; }
  h1 { font-size: 2.45rem; }
  .section { padding: 58px 0; }
  .section-heading { align-items: start; flex-direction: column; gap: 10px; }
  .cards, .post-grid, .archive-grid, .footer-grid, .sidebar, .tool-link-grid { grid-template-columns: 1fr; }
  .cta { padding: 30px 24px; }
  .hero-card { padding: 20px; }
  .search-form { flex-direction: column; }
}
