/*
Theme Name: Personal Tracker Theme
Theme URI: https://example.local/personal-tracker-theme
Author: Custom App Architect
Description: Minimal app-shell theme untuk Personal Tracker App. Dirancang untuk dashboard Revenue & Habit Tracker berbasis custom plugin.
Version: 1.0.15
Requires at least: 6.0
Requires PHP: 7.4
Text Domain: personal-tracker-theme
*/

:root {
    --ptt-bg: #a9dfdd;
    --ptt-ink: #142624;
    --ptt-muted: #617471;
}

html,
body {
    margin: 0;
    padding: 0;
}

body {
    min-height: 100vh;
    color: var(--ptt-ink);
    background:
        radial-gradient(circle at 10% 10%, rgba(255,255,255,.45), transparent 260px),
        radial-gradient(circle at 84% 6%, rgba(255,255,255,.22), transparent 220px),
        linear-gradient(135deg, #b8e6e5 0%, #a7dedc 42%, #7cc8c8 100%);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

a {
    color: inherit;
}

/* Force app-like frontend: no WordPress admin bar spacing on tracker UI. */
html.pta-no-adminbar,
body.pta-no-adminbar,
body.admin-bar.pta-theme-active {
    margin-top: 0 !important;
}

body.pta-theme-active #wpadminbar {
    display: none !important;
}

.ptt-site {
    min-height: 100vh;
}

.ptt-content {
    padding: 1px 0;
}

.ptt-plain-page {
    width: min(920px, calc(100vw - 32px));
    margin: 48px auto;
    padding: 38px;
    border-radius: 32px;
    background: rgba(255,255,255,.94);
    box-shadow: 0 24px 70px rgba(14, 70, 66, .15);
}

.ptt-plain-page h1 {
    margin-top: 0;
    letter-spacing: -.04em;
}

/* v1.0.6 custom homepage/login/dashboard shell */
.ptt-login-screen,
.ptt-login-screen * {
    box-sizing: border-box;
}

.ptt-login-screen {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 28px;
}

.ptt-login-card {
    width: min(1060px, 100%);
    min-height: 640px;
    display: grid;
    grid-template-columns: minmax(0, 1.08fr) minmax(380px, .92fr);
    overflow: hidden;
    border-radius: 38px;
    background: rgba(255,255,255,.92);
    border: 1px solid rgba(255,255,255,.82);
    box-shadow: 0 32px 90px rgba(14, 70, 66, .18);
}

.ptt-login-visual {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 38px;
    color: #fff;
    background:
        radial-gradient(circle at 18% 18%, rgba(255,255,255,.35), transparent 170px),
        radial-gradient(circle at 90% 8%, rgba(185,230,101,.35), transparent 210px),
        linear-gradient(145deg, #087b72 0%, #0f3842 58%, #102b36 100%);
}

.ptt-login-visual:after {
    content: "";
    position: absolute;
    inset: auto -8% -22% 18%;
    height: 240px;
    border-radius: 999px 999px 0 0;
    background:
        repeating-linear-gradient(160deg, rgba(255,255,255,.12) 0 1px, transparent 1px 28px),
        linear-gradient(135deg, rgba(185,230,101,.45), rgba(255,138,61,.38));
    transform: rotate(-5deg);
}

.ptt-login-brand {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 13px;
    line-height: 1;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: -.03em;
}

.ptt-login-mark {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: #087b72;
    background: #fff;
    box-shadow: 0 18px 38px rgba(0,0,0,.15);
}

.ptt-login-copy {
    position: relative;
    z-index: 1;
    max-width: 520px;
}

.ptt-login-kicker {
    display: inline-flex;
    margin-bottom: 12px;
    padding: 7px 11px;
    border-radius: 999px;
    background: rgba(255,255,255,.18);
    color: inherit;
    font-size: 11px;
    font-weight: 900;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.ptt-login-copy h1 {
    margin: 0;
    font-size: clamp(38px, 5vw, 62px);
    line-height: .94;
    letter-spacing: -.07em;
}

.ptt-login-copy p {
    max-width: 430px;
    margin: 20px 0 0;
    color: rgba(255,255,255,.78);
    line-height: 1.7;
}

.ptt-login-stats {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.ptt-login-stats div {
    padding: 16px;
    border-radius: 22px;
    background: rgba(255,255,255,.13);
    border: 1px solid rgba(255,255,255,.18);
    backdrop-filter: blur(10px);
}

.ptt-login-stats strong,
.ptt-login-stats span {
    display: block;
}

.ptt-login-stats span {
    margin-top: 5px;
    color: rgba(255,255,255,.72);
    font-size: 12px;
}

.ptt-login-form-wrap {
    padding: 54px 46px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.ptt-login-form-wrap .ptt-login-kicker {
    width: fit-content;
    background: #e9f5f2;
    color: #087b72;
}

.ptt-login-form-wrap h2 {
    margin: 0;
    font-size: 38px;
    line-height: 1;
    letter-spacing: -.06em;
}

.ptt-login-form-wrap p {
    margin: 12px 0 24px;
    color: var(--ptt-muted);
    line-height: 1.6;
}

.ptt-login-error {
    margin-bottom: 16px;
    padding: 12px 14px;
    border-radius: 16px;
    color: #9a3412;
    background: #fff1e8;
    border: 1px solid #fed7aa;
    font-size: 13px;
    font-weight: 700;
}

.ptt-login-form {
    display: grid;
    gap: 14px;
}

.ptt-login-form label span {
    display: block;
    margin-bottom: 8px;
    color: #344b49;
    font-size: 13px;
    font-weight: 800;
}

.ptt-login-form input[type="text"],
.ptt-login-form input[type="password"] {
    width: 100%;
    min-height: 52px;
    border: 1px solid rgba(23,35,34,.10);
    border-radius: 17px;
    padding: 0 16px;
    outline: none;
    background: #f7fbfa;
    color: var(--ptt-ink);
    font: inherit;
    transition: border-color .18s ease, box-shadow .18s ease, background-color .18s ease;
}

.ptt-login-form input[type="text"]:focus,
.ptt-login-form input[type="password"]:focus {
    border-color: #087b72;
    background: #fff;
    box-shadow: 0 0 0 4px rgba(8,123,114,.10);
}

.ptt-login-remember {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 2px 0 8px;
}

.ptt-login-remember input {
    width: 17px;
    height: 17px;
    accent-color: #087b72;
}

.ptt-login-remember span {
    margin: 0 !important;
    color: var(--ptt-muted);
}

.ptt-login-form button {
    min-height: 54px;
    border: 0;
    border-radius: 18px;
    background: linear-gradient(135deg, #ff8a3d, #e06f25);
    color: #fff;
    font: inherit;
    font-weight: 900;
    cursor: pointer;
    box-shadow: 0 18px 34px rgba(255, 138, 61, .27);
    transition: transform .18s ease, box-shadow .18s ease;
}

.ptt-login-form button:hover {
    transform: translateY(-1px);
    box-shadow: 0 20px 38px rgba(255, 138, 61, .32);
}

@media (max-width: 860px) {
    .ptt-login-screen {
        padding: 0;
        place-items: stretch;
    }

    .ptt-login-card {
        min-height: 100vh;
        grid-template-columns: 1fr;
        border-radius: 0;
    }

    .ptt-login-visual {
        min-height: 360px;
        padding: 28px;
    }

    .ptt-login-form-wrap {
        padding: 34px 24px 42px;
    }

    .ptt-login-stats {
        grid-template-columns: 1fr;
    }
}

/* v1.0.6: compact login/home typography. */
.ptt-login-card {
    min-height: 600px;
    border-radius: 32px;
}

.ptt-login-visual {
    padding: 34px;
}

.ptt-login-copy h1 {
    font-size: clamp(34px, 4.2vw, 50px);
    line-height: .98;
}

.ptt-login-copy p {
    font-size: 14px;
    line-height: 1.65;
}

.ptt-login-form-wrap {
    padding: 44px 40px;
}

.ptt-login-form-wrap h2 {
    font-size: 30px;
}

@media (max-width: 760px) {
    .ptt-login-card {
        min-height: 0;
        border-radius: 26px;
    }

    .ptt-login-visual,
    .ptt-login-form-wrap {
        padding: 26px 22px;
    }

    .ptt-login-copy h1 {
        font-size: 34px;
    }
}

/* v1.0.9: let the tracker app use the full viewport. */
body.pta-theme-active .ptt-site,
body.pta-theme-active .ptt-content {
    min-height: 100vh;
    padding: 0 !important;
}

body.pta-theme-active {
    overflow-x: hidden;
}

/* v1.0.11: improve mobile login spacing and visual breathing room. */
@media (max-width: 860px) {
    .ptt-login-visual {
        justify-content: flex-start;
        gap: 30px;
        padding: 34px 28px 42px;
    }

    .ptt-login-brand {
        margin-bottom: 8px;
    }

    .ptt-login-copy {
        display: grid;
        gap: 20px;
    }

    .ptt-login-copy .ptt-login-kicker {
        margin-bottom: 0;
        width: fit-content;
    }

    .ptt-login-copy h1 {
        font-size: clamp(38px, 11vw, 48px);
        line-height: 1.02;
    }

    .ptt-login-copy p {
        margin: 0;
        font-size: 18px;
        line-height: 1.65;
    }

    .ptt-login-stats {
        gap: 18px;
        margin-top: 6px;
    }

    .ptt-login-stats div {
        padding: 20px;
        border-radius: 24px;
    }

    .ptt-login-form-wrap {
        padding-top: 40px;
    }
}

@media (max-width: 480px) {
    .ptt-login-visual {
        gap: 34px;
        padding: 32px 26px 46px;
    }

    .ptt-login-brand {
        gap: 16px;
    }

    .ptt-login-mark {
        width: 54px;
        height: 54px;
    }

    .ptt-login-copy {
        gap: 22px;
    }

    .ptt-login-kicker {
        padding: 10px 16px;
        font-size: 12px;
    }

    .ptt-login-copy h1 {
        font-size: clamp(36px, 10.3vw, 43px);
        letter-spacing: -.065em;
    }

    .ptt-login-copy p {
        font-size: 17px;
        line-height: 1.75;
    }

    .ptt-login-stats {
        gap: 20px;
        margin-top: 2px;
    }

    .ptt-login-stats div {
        padding: 18px 20px;
    }
}
