:root {
	--dgf-app-sidebar: 268px;
	--dgf-app-bg: #f3f4f6;
	--dgf-app-dark: #0d1014;
	--dgf-app-dark-soft: #171b21;
	--dgf-app-accent: #6cff7d;
	--dgf-app-text: #15171a;
	--dgf-app-muted: #707783;
	--dgf-app-line: #dfe3e8;
}

html, body { margin: 0; min-height: 100%; }
body.dgf-app-page, body.dgf-login-page { background: var(--dgf-app-bg); color: var(--dgf-app-text); font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
body.dgf-app-page * , body.dgf-login-page * { box-sizing: border-box; }
body.dgf-app-page a, body.dgf-login-page a { color: inherit; }

/* Application shell */
.dgf-app { min-height: 100vh; display: grid; grid-template-columns: var(--dgf-app-sidebar) minmax(0, 1fr); }
.dgf-app-sidebar { position: fixed; inset: 0 auto 0 0; z-index: 100; width: var(--dgf-app-sidebar); display: flex; flex-direction: column; padding: 24px 16px 18px; background: var(--dgf-app-dark); color: #fff; border-right: 1px solid #272c34; }
.dgf-app-logo { min-height: 62px; display: flex; align-items: center; gap: 13px; padding: 0 10px 20px; text-decoration: none; border-bottom: 1px solid #292e36; }
.dgf-app-logo-mark { width: 42px; height: 42px; display: grid; place-items: center; background: #fff; color: #0c0f13; font-size: 17px; font-weight: 900; letter-spacing: -.08em; }
.dgf-app-logo-mark span { color: #21b838; }
.dgf-app-logo > span:last-child { display: flex; flex-direction: column; line-height: 1; }
.dgf-app-logo b { font-size: 15px; letter-spacing: .08em; }
.dgf-app-logo small { margin-top: 6px; color: var(--dgf-app-accent); font-size: 10px; font-weight: 800; letter-spacing: .26em; }
.dgf-app-nav { display: grid; gap: 5px; padding: 28px 0; }
.dgf-app-nav-item { min-height: 47px; display: flex; align-items: center; gap: 13px; padding: 0 14px; color: #aeb5bf !important; text-decoration: none; border-left: 3px solid transparent; transition: .18s ease; }
.dgf-app-nav-item .dashicons { width: 20px; height: 20px; font-size: 20px; }
.dgf-app-nav-item:hover { background: #181d23; color: #fff !important; }
.dgf-app-nav-item.is-active { background: #1b211f; color: #fff !important; border-left-color: var(--dgf-app-accent); }
.dgf-app-nav-item.is-active .dashicons { color: var(--dgf-app-accent); }
.dgf-app-sidebar-bottom { margin-top: auto; }
.dgf-app-sidebar-bottom > .dgf-app-nav-item { margin-bottom: 14px; }
.dgf-app-user { min-height: 68px; display: grid; grid-template-columns: 42px minmax(0,1fr) 30px; align-items: center; gap: 11px; padding: 13px 8px 0; border-top: 1px solid #292e36; }
.dgf-app-user img { width: 42px; height: 42px; object-fit: cover; }
.dgf-app-user strong, .dgf-app-user span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dgf-app-user strong { font-size: 13px; }
.dgf-app-user span { margin-top: 4px; color: #828b97; font-size: 10px; text-transform: uppercase; letter-spacing: .08em; }
.dgf-app-user > a { width: 30px; height: 30px; display: grid; place-items: center; color: #8e96a1; text-decoration: none; }
.dgf-app-user > a:hover { color: #fff; }
.dgf-app-main { grid-column: 2; min-width: 0; min-height: 100vh; }
.dgf-app-topbar { position: sticky; top: 0; z-index: 60; min-height: 72px; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 0 30px; background: rgba(255,255,255,.96); border-bottom: 1px solid var(--dgf-app-line); backdrop-filter: blur(14px); }
.dgf-app-topbar > div:nth-child(2) { display: flex; flex-direction: column; }
.dgf-app-location { color: #8a929e; font-size: 9px; line-height: 1; font-weight: 800; letter-spacing: .19em; }
.dgf-app-topbar strong { margin-top: 6px; font-size: 15px; }
.dgf-app-top-actions { display: flex; align-items: center; gap: 18px; color: var(--dgf-app-muted); font-size: 12px; }
.dgf-app-quick { min-height: 38px; display: inline-flex; align-items: center; gap: 7px; padding: 0 15px; background: var(--dgf-app-dark); color: #fff !important; font-weight: 700; text-decoration: none; }
.dgf-app-quick:hover { background: #252b33; }
.dgf-app-menu-toggle { display: none; width: 42px; height: 42px; padding: 0; border: 1px solid var(--dgf-app-line); background: #fff; }
.dgf-app-content { min-width: 0; }
.dgf-app-overlay { display: none; }

/* Make admin-generated CRM views native on the frontend. */
.dgf-app-content .dgf-wrap { margin: 0 30px 50px; }
.dgf-app-content .dgf-header { margin: 0 -30px 28px; padding: 38px 38px 34px; }
.dgf-app-content .button { min-height: 36px; display: inline-flex; align-items: center; justify-content: center; padding: 0 13px; background: #fff; color: #1d2327; font-size: 13px; line-height: 1; font-weight: 600; text-decoration: none; border: 1px solid #aeb4bd; cursor: pointer; border-radius: 0; }
.dgf-app-content .button:hover { border-color: #15191f; color: #15191f; }
.dgf-app-content .button-primary { background: #15191f; color: #fff; border-color: #15191f; }
.dgf-app-content .button-primary:hover { background: #2b3139; color: #fff; border-color: #2b3139; }
.dgf-app-content .button-large { min-height: 43px; padding-inline: 18px; }
.dgf-app-content .button-link-delete { background: transparent; border-color: transparent; }
.dgf-app-content table { width: 100%; border-collapse: collapse; }
.dgf-app-content .widefat { background: #fff; color: var(--dgf-app-text); }
.dgf-app-content .widefat th { text-align: left; }
.dgf-app-content .widefat td, .dgf-app-content .widefat th { border-bottom: 1px solid #e7e9ed; }
.dgf-app-content input, .dgf-app-content select, .dgf-app-content textarea, .dgf-app-content button { font: inherit; }
.dgf-app-content select { appearance: auto; }
.dgf-app-content .notice { margin: 0 0 18px; padding: 13px 16px; background: #fff; border: 1px solid var(--dgf-app-line); border-left: 4px solid #2271b1; }
.dgf-app-content .notice-success { border-left-color: #21a13a; }
.dgf-app-content .notice-error { border-left-color: #d63638; }
.dgf-app-content .notice p { margin: 0; }
.dgf-app-content .notice-dismiss { display: none; }

/* Login */
.dgf-login-shell { min-height: 100vh; display: grid; grid-template-columns: minmax(360px, 1.15fr) minmax(420px, .85fr); background: var(--dgf-app-dark); }
.dgf-login-brand { position: relative; display: flex; align-items: center; gap: 28px; padding: clamp(50px, 8vw, 130px); overflow: hidden; color: #fff; }
.dgf-login-brand::before { content: ""; position: absolute; width: 520px; height: 520px; right: -130px; bottom: -210px; border: 1px solid rgba(108,255,125,.24); transform: rotate(18deg); }
.dgf-login-brand::after { content: ""; position: absolute; width: 230px; height: 4px; left: clamp(50px, 8vw, 130px); bottom: 12%; background: var(--dgf-app-accent); }
.dgf-login-mark { position: relative; z-index: 1; width: 92px; height: 92px; flex: 0 0 92px; display: grid; place-items: center; background: #fff; color: #0c0f13; font-size: 34px; font-weight: 900; letter-spacing: -.1em; }
.dgf-login-mark span { color: #21b838; }
.dgf-login-brand > div:last-child { position: relative; z-index: 1; }
.dgf-login-eyebrow { color: #8b949f; font-size: 11px; font-weight: 800; letter-spacing: .35em; }
.dgf-login-brand h1 { margin: 7px 0 16px; font-size: clamp(58px, 7vw, 112px); line-height: .86; letter-spacing: -.075em; }
.dgf-login-brand p { max-width: 470px; margin: 0; color: #aeb5bf; font-size: 17px; line-height: 1.65; }
.dgf-login-card { display: flex; flex-direction: column; justify-content: center; padding: clamp(44px, 7vw, 110px); background: #fff; }
.dgf-login-kicker { color: #7d8590; font-size: 10px; font-weight: 800; letter-spacing: .24em; }
.dgf-login-card h2 { margin: 12px 0 8px; font-size: clamp(34px, 4vw, 58px); line-height: 1; letter-spacing: -.05em; }
.dgf-login-intro { margin: 0 0 34px; color: var(--dgf-app-muted); }
.dgf-login-error { margin-bottom: 20px; padding: 13px 15px; background: #fff2f2; color: #a41719; border-left: 4px solid #d63638; }
.dgf-login-form { display: grid; gap: 18px; }
.dgf-login-form label:not(.dgf-login-remember) { display: grid; gap: 8px; }
.dgf-login-form label > span { font-size: 12px; font-weight: 750; }
.dgf-login-form input[type="text"], .dgf-login-form input[type="password"] { width: 100%; min-height: 52px; padding: 0 15px; font: inherit; border: 1px solid #cbd0d7; border-radius: 0; outline: none; }
.dgf-login-form input:focus { border-color: #111419; box-shadow: 0 0 0 1px #111419; }
.dgf-login-remember { display: flex; align-items: center; gap: 9px; color: var(--dgf-app-muted); font-size: 12px; }
.dgf-login-form button, .dgf-login-button { min-height: 54px; display: inline-flex; align-items: center; justify-content: space-between; padding: 0 20px; background: var(--dgf-app-dark); color: #fff !important; font: inherit; font-weight: 750; text-decoration: none; border: 0; border-bottom: 4px solid var(--dgf-app-accent); border-radius: 0; cursor: pointer; }
.dgf-login-form button:hover, .dgf-login-button:hover { background: #242a31; }
.dgf-login-help { margin-top: 20px; color: #5f6874 !important; font-size: 12px; text-decoration: none; }
.dgf-login-help:hover { text-decoration: underline; }

@media (max-width: 1100px) {
	.dgf-app { grid-template-columns: 1fr; }
	.dgf-app-sidebar { transform: translateX(-100%); transition: transform .22s ease; box-shadow: 18px 0 45px rgba(0,0,0,.18); }
	.dgf-app-main { grid-column: 1; }
	.dgf-app-menu-toggle { display: grid; place-items: center; }
	.dgf-app.is-menu-open .dgf-app-sidebar { transform: translateX(0); }
	.dgf-app-overlay { position: fixed; inset: 0; z-index: 90; background: rgba(7,9,12,.58); }
	.dgf-app.is-menu-open .dgf-app-overlay { display: block; }
	.dgf-login-shell { grid-template-columns: 1fr; }
	.dgf-login-brand { min-height: 38vh; padding: 50px; }
	.dgf-login-brand::after { left: 50px; }
	.dgf-login-card { min-height: 62vh; padding: 50px; }
}

@media (max-width: 700px) {
	.dgf-app-topbar { min-height: 64px; padding: 0 14px; }
	.dgf-app-topbar > div:nth-child(2) { margin-right: auto; }
	.dgf-app-top-actions > span { display: none; }
	.dgf-app-quick { width: 40px; padding: 0; justify-content: center; font-size: 0; }
	.dgf-app-content .dgf-wrap { margin: 0 14px 34px; }
	.dgf-app-content .dgf-header { margin: 0 -14px 20px; padding: 28px 20px; }
	.dgf-login-brand { min-height: 34vh; gap: 18px; padding: 32px 24px; }
	.dgf-login-brand::after { left: 24px; }
	.dgf-login-mark { width: 62px; height: 62px; flex-basis: 62px; font-size: 23px; }
	.dgf-login-brand h1 { font-size: 54px; }
	.dgf-login-brand p { font-size: 14px; }
	.dgf-login-card { min-height: 66vh; padding: 38px 24px; }
}
