/*
Theme Name: Shopping App Plain
Theme URI: https://example.com/
Author: Codex
Author URI: https://example.com/
Description: A plain app-like WordPress theme designed for the Shared Shopping Stock List plugin. No sidebars, widget columns, or clutter.
Version: 1.0.1
Requires at least: 6.0
Tested up to: 6.8
Requires PHP: 7.4
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: shopping-app-plain
*/

:root {
    --sap-page: #f4f6f8;
    --sap-surface: #ffffff;
    --sap-text: #17202a;
    --sap-muted: #647282;
    --sap-border: #d8dee6;
    --sap-accent: #147d64;
    --sap-accent-dark: #0e5f4c;
    --sap-danger: #b42318;
    --sap-shadow: 0 18px 45px rgba(23, 32, 42, .08);
}

* { box-sizing: border-box; }

html {
    min-height: 100%;
    background: var(--sap-page);
    -webkit-text-size-adjust: 100%;
}

body {
    min-height: 100%;
    margin: 0;
    color: var(--sap-text);
    background: var(--sap-page);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
    font-size: 16px;
    line-height: 1.5;
}

a { color: var(--sap-accent); }
a:hover { color: var(--sap-accent-dark); }

button,
input,
textarea,
select {
    max-width: 100%;
    font: inherit;
}

button { cursor: pointer; }

.site-shell {
    min-height: 100vh;
    display: grid;
    grid-template-rows: auto 1fr auto;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 20;
    border-bottom: 1px solid var(--sap-border);
    background: rgba(255, 255, 255, .94);
    backdrop-filter: blur(12px);
}

.site-header-inner {
    width: min(1120px, calc(100% - 32px));
    min-height: 64px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.site-branding { min-width: 0; }

.site-title {
    margin: 0;
    font-size: 20px;
    line-height: 1.2;
    font-weight: 800;
}

.site-title a {
    color: var(--sap-text);
    text-decoration: none;
}

.site-description {
    margin: 2px 0 0;
    color: var(--sap-muted);
    font-size: 13px;
}

.site-nav { display: flex; align-items: center; gap: 8px; }

.site-nav ul,
.site-nav .menu {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 6px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.site-nav a {
    display: block;
    border: 1px solid transparent;
    border-radius: 6px;
    padding: 7px 10px;
    color: var(--sap-text);
    text-decoration: none;
    font-size: 14px;
    font-weight: 700;
}

.site-nav a:hover,
.site-nav .current-menu-item > a,
.site-nav .current_page_item > a {
    border-color: var(--sap-border);
    background: #f7f9fb;
}

.site-main {
    width: min(1120px, calc(100% - 32px));
    margin: 0 auto;
    padding: 28px 0 36px;
}

.content-panel {
    min-height: calc(100vh - 164px);
    border: 1px solid var(--sap-border);
    border-radius: 8px;
    padding: clamp(16px, 3vw, 28px);
    background: var(--sap-surface);
    box-shadow: var(--sap-shadow);
}

.entry-header { margin-bottom: 18px; }

.entry-title {
    margin: 0;
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.1;
    letter-spacing: 0;
}

.entry-content > *:first-child { margin-top: 0; }
.entry-content > *:last-child { margin-bottom: 0; }
.entry-content img { max-width: 100%; height: auto; }

.entry-content table {
    width: 100%;
    border-collapse: collapse;
}

.entry-content th,
.entry-content td {
    border-bottom: 1px solid var(--sap-border);
    padding: 10px;
    text-align: left;
}

.entry-content .ssl-app {
    max-width: none;
    margin: 0;
}

.entry-content .ssl-app button,
.entry-content .ssl-app input,
.entry-content .ssl-app select {
    min-height: 42px;
}

.site-footer {
    border-top: 1px solid var(--sap-border);
    color: var(--sap-muted);
    background: #ffffff;
}

.site-footer-inner {
    width: min(1120px, calc(100% - 32px));
    margin: 0 auto;
    padding: 14px 0;
    font-size: 13px;
}

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

.screen-reader-text:focus {
    z-index: 100000;
    top: 8px;
    left: 8px;
    width: auto;
    height: auto;
    padding: 10px 12px;
    clip: auto;
    background: #fff;
    border: 1px solid var(--sap-border);
    border-radius: 6px;
}

@media (max-width: 720px) {
    .site-header { position: static; }

    .site-header-inner {
        min-height: 58px;
        align-items: flex-start;
        flex-direction: column;
        padding: 12px 0;
    }

    .site-nav,
    .site-nav ul,
    .site-nav .menu {
        width: 100%;
        justify-content: flex-start;
    }

    .site-main {
        width: min(100% - 20px, 1120px);
        padding: 10px 0 20px;
    }

    .content-panel {
        min-height: calc(100vh - 140px);
        padding: 14px;
    }

    .entry-header { margin-bottom: 14px; }
}
