/* Together SMS shell v1: existing operational assets remain loaded. */
html{color-scheme:light}
body.tg-portal{
    --tg-ink:#17263c;--tg-muted:#64748b;--tg-line:#e5eaf0;
    --tg-accent:#ffcc06;--tg-bg:#f5f7fa;
    margin:0!important;width:100%!important;min-width:0!important;
    background:var(--tg-bg)!important;color:var(--tg-ink);
    font:14px/1.7 "Segoe UI",Tahoma,Arial,sans-serif;
}
.tg-app,.tg-app *{box-sizing:border-box}
.tg-app a{color:inherit;text-decoration:none}
.tg-app a:focus-visible,.tg-app button:focus-visible,.tg-app summary:focus-visible{
    outline:3px solid #d79b00;outline-offset:4px
}
.tg-skip{position:fixed;top:-100px;inset-inline-start:20px;z-index:10000;padding:12px 20px;background:#fff;color:#17263c}
.tg-skip:focus{top:12px}
.tg-app{display:flex;min-height:100vh;width:100%;text-align:start}
.tg-sidebar{
    width:254px;flex:0 0 254px;background:#fff;border-inline-end:1px solid var(--tg-line);
    padding:28px 17px;position:sticky;top:0;height:100vh;overflow:auto;
    display:flex;flex-direction:column;z-index:40
}
.tg-brand{display:flex;align-items:center;flex-direction:column;gap:8px;padding:0 15px 26px}
.tg-brand img{display:block;max-width:100%;height:auto;object-fit:contain}
.tg-brand>span{font:10px/1.5 "Segoe UI",Arial,sans-serif;letter-spacing:3px;color:#758193}
.tg-nav-label{font-size:11px;font-weight:700;color:#94a0ae;padding:14px 15px 10px;letter-spacing:.6px}
.tg-navigation ul{list-style:none;margin:0;padding:0;background:none;border:0;width:auto}
.tg-navigation li{display:block;float:none!important;margin:3px 0;padding:0;background:none;width:auto}
.tg-navigation a{
    display:flex;align-items:center;gap:10px;padding:10px 14px;
    border-radius:10px;color:#526176;font-weight:600;font-size:13px;line-height:1.65;
    border:1px solid transparent;transition:background .15s,color .15s
}
.tg-navigation a:before{content:"";width:6px;height:6px;flex:0 0 6px;border:1.5px solid #a3adba;border-radius:2px}
.tg-navigation a:hover{background:#f4f6f9;color:#17263c}
.tg-navigation a[aria-current="page"]{background:#fff7d6;border-color:#ffed9f;color:#503d00}
.tg-navigation a[aria-current="page"]:before{background:#d79b00;border-color:#d79b00}
.tg-sidebar-bottom{margin-top:auto;padding:25px 15px 0;display:flex;align-items:center;gap:9px;color:#8390a0;font-size:11px}
.tg-status-dot{width:6px;height:6px;background:#e5b800;border-radius:50%;display:inline-block}
.tg-workspace{flex:1;min-width:0;display:flex;flex-direction:column}
.tg-topbar{
    min-height:88px;background:#fff;border-bottom:1px solid var(--tg-line);
    display:flex;align-items:center;gap:18px;padding:16px 36px
}
.tg-topbar-heading{display:flex;flex-direction:column;gap:1px;min-width:0}
.tg-topbar-heading>span{font-size:11px;color:var(--tg-muted)}
.tg-topbar-heading>strong{font-size:14px;font-weight:600}
.tg-topbar-actions{margin-inline-start:auto;display:flex;align-items:center;gap:22px}
.tg-language{display:flex;gap:5px;align-items:center;direction:ltr}
.tg-language a{padding:3px 7px;font-size:12px;color:#788697;border-radius:5px}
.tg-language a[aria-current="true"]{background:#f0f3f7;color:#17263c}
.tg-account{position:relative}
.tg-account summary{display:flex;align-items:center;gap:10px;cursor:pointer;list-style:none}
.tg-account summary::-webkit-details-marker{display:none}
.tg-avatar{width:39px;height:39px;border-radius:12px;display:grid;place-items:center;background:#fff6d0;color:#806000}
.tg-account-name{display:flex;flex-direction:column;line-height:1.5}
.tg-account-name small{font-size:10px;color:var(--tg-muted)}
.tg-account-name b{max-width:180px;overflow:hidden;text-overflow:ellipsis;font-size:13px}
.tg-account-menu{
    position:absolute;inset-inline-end:0;top:calc(100% + 17px);
    width:250px;padding:8px;background:#fff;border:1px solid var(--tg-line);
    box-shadow:0 18px 50px #17263c18;border-radius:14px;z-index:60
}
.tg-account-menu a{display:block;padding:9px 12px;border-radius:7px;font-size:13px}
.tg-account-menu a:hover{background:#f5f7fa}
.tg-account-menu .tg-logout{color:#b33c35;border-top:1px solid #edf0f4;margin-top:5px;padding-top:12px}
.tg-session-note{padding:5px 12px;color:var(--tg-muted);font-size:12px}
.tg-menu-toggle{display:none;border:1px solid var(--tg-line);background:white;border-radius:8px;padding:8px;color:#17263c;cursor:pointer}
.tg-main{width:100%;max-width:1536px;margin:0 auto;padding:36px;flex:1;outline:none}
.tg-page-heading{display:flex;align-items:center;justify-content:space-between;gap:20px;margin-bottom:24px}
.tg-eyebrow{font:10px/1.5 "Segoe UI",Arial,sans-serif;letter-spacing:2px;color:#8a96a6;margin:0 0 5px}
.tg-page-heading h1{font-size:26px;line-height:1.5;margin:0;font-weight:700;color:#17263c}
.tg-primary,.tg-login-link{
    display:inline-flex;align-items:center;justify-content:center;gap:8px;
    padding:10px 20px;background:#17263c;color:#fff!important;border-radius:9px;
    font-weight:600;font-size:13px;white-space:nowrap
}
.tg-primary:hover,.tg-login-link:hover{background:#293e5b}
.tg-account-stats{display:flex;flex-wrap:wrap;gap:12px;margin-bottom:24px}
.tg-stat{background:#fff;border:1px solid var(--tg-line);padding:12px 18px;border-radius:10px;color:#42536a;font-size:13px}
.tg-page-banner:empty{display:none}
.tg-page-banner img{max-width:100%;height:auto}
.tg-content{min-width:0}
.tg-content>.home_page{width:100%;float:none;background:none;padding:0;margin:0}
.tg-content form{max-width:100%}
.tg-content table{max-width:100%}
.tg-content textarea{max-width:100%;border-radius:8px;border-color:#ccd5df;padding:12px;font-family:inherit}
.tg-content input[type=text],.tg-content input[type=password],.tg-content input[type=email],
.tg-content select{max-width:100%;border:1px solid #ccd5df;border-radius:7px;min-height:36px;font-family:inherit}
.tg-content input:focus,.tg-content textarea:focus,.tg-content select:focus{
    outline:2px solid #ffcc0670;outline-offset:1px;border-color:#c99900
}
.tg-footer{border-top:1px solid var(--tg-line);background:#fff;padding:24px 36px;color:#788697}
.tg-footer-links{display:flex;gap:32px;flex-wrap:wrap}
.tg-footer-links .one_item_footer{float:none;width:auto;min-width:140px;margin:0;padding:0;border:0;background:none}
.tg-footer-links .img_item_footer{display:none}
.tg-footer-links .title_item_footer{background:none;font-size:12px;font-weight:700;color:#536278;margin-bottom:6px}
.tg-footer-links .links_item_footer{background:none;padding:0}
.tg-footer-links a{display:block;font-size:12px;padding:3px 0}
.tg-footer .copy_right{background:none;border:0;float:none;width:auto;padding:16px 0 0;margin:12px 0 0;font-size:10px;color:#8c97a5;text-align:start}
.tg-footer .copy_right p{margin:2px 0}
.tg-dashboard{display:grid;gap:24px}
.tg-quick-actions{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px}
.tg-quick-card{
    display:flex;align-items:flex-start;gap:15px;padding:24px 20px;background:#fff;
    border:1px solid var(--tg-line);border-radius:15px;min-height:125px;
    box-shadow:0 3px 10px #17263c03;transition:transform .15s,border-color .15s
}
.tg-quick-card:hover{transform:translateY(-3px);border-color:#e4c96a}
.tg-quick-icon{width:44px;height:44px;border-radius:12px;background:#fff8db;color:#826300;display:grid;place-items:center;flex:0 0 44px}
.tg-quick-card strong{display:block;font-size:14px;color:#17263c;margin:2px 0 5px}
.tg-quick-card small{display:block;font-size:11px;color:#8591a0;line-height:1.7}
.tg-chart-card{padding:26px;background:#fff;border:1px solid var(--tg-line);border-radius:15px;min-width:0}
.tg-chart-heading{margin-bottom:22px}
.tg-chart-heading h2{margin:0 0 4px;font-size:17px;color:#17263c}
.tg-chart-heading p{margin:0;color:#8491a2;font-size:12px}
.tg-chart-host{max-width:100%;overflow-x:auto}
.tg-chart-host canvas{max-width:100%}
@media(min-width:1600px){.tg-main{padding:42px 48px}}
@media(max-width:1200px){
    .tg-sidebar{width:225px;flex-basis:225px}
    .tg-main{padding:26px}
    .tg-quick-actions{grid-template-columns:repeat(2,minmax(0,1fr))}
    .tg-topbar{padding:16px 26px}
}
@media(max-width:850px){
    .tg-sidebar{position:fixed;inset-inline-start:0;top:0;width:254px;display:none;box-shadow:0 0 0 100vmax #17263c55}
    .tg-portal.tg-nav-open .tg-sidebar{display:flex}
    .tg-menu-toggle{display:inline-flex}
    .tg-topbar{padding:13px 18px;min-height:76px;position:relative;z-index:45}
    .tg-topbar-actions{gap:12px}
    .tg-main{padding:24px 18px}
    .tg-page-heading h1{font-size:22px}
    .tg-footer{padding:24px 18px}
}
@media(max-width:520px){
    .tg-topbar-heading{display:none}
    .tg-account-name b{max-width:110px}
    .tg-page-heading{align-items:flex-start}
    .tg-primary{padding:9px 12px;font-size:12px}
    .tg-quick-actions{gap:10px}
    .tg-quick-card{padding:17px 13px;display:block;min-height:155px}
    .tg-quick-icon{margin-bottom:12px}
    .tg-quick-card strong{font-size:13px}
    .tg-stat{width:100%}
    .tg-chart-card{padding:18px}
}
@media(prefers-reduced-motion:reduce){.tg-app *{transition:none!important;scroll-behavior:auto!important}}

/* Together visual refinements v1 */
body.tg-portal{font-size:15px}
.tg-sidebar{overflow-x:hidden;overflow-y:auto;scrollbar-width:thin}
.tg-navigation{
    display:block;min-width:0!important;width:100%!important;
    max-width:100%!important;overflow:visible
}
.tg-navigation ul,.tg-navigation li{
    min-width:0!important;width:100%!important;max-width:100%!important;
    float:none!important;position:static!important;
    margin-inline:0!important;box-sizing:border-box
}
.tg-navigation li{height:auto!important}
.tg-navigation li>a{
    display:flex!important;float:none!important;width:100%!important;
    max-width:100%!important;min-width:0!important;height:auto!important;
    white-space:normal!important;overflow-wrap:break-word;
    font-size:14px;line-height:1.75;text-align:start
}
.tg-navigation a span{
    display:block!important;float:none!important;position:static!important;
    min-width:0!important;width:auto!important;max-width:100%!important;
    height:auto!important;margin:0!important;padding:0!important;
    background:none!important;white-space:normal!important;
    font:inherit!important;line-height:inherit!important;overflow-wrap:break-word
}
.tg-sidebar-bottom{min-width:0;flex-shrink:0}
.tg-sidebar-bottom>span:last-child{min-width:0;white-space:normal}
.tg-stat{font-size:14px}
.tg-quick-card strong{font-size:15px}
.tg-quick-card small{font-size:12px}
.tg-chart-heading p{font-size:13px}
.tg-footer-links{
    display:grid;grid-template-columns:repeat(3,minmax(0,1fr));
    gap:28px;align-items:start;width:100%
}
.tg-footer .one_item_footer{
    display:block!important;float:none!important;position:static!important;
    min-width:0!important;width:100%!important;max-width:100%!important;
    height:auto!important;border:0!important;padding:0!important;margin:0!important
}
.tg-footer .title_item_footer{
    display:block!important;float:none!important;width:auto!important;
    height:auto!important;text-align:start!important;
    margin:0 0 10px!important;padding:0!important;line-height:1.8;
    background:none!important;font-size:13px
}
.tg-footer .links_item_footer{
    display:block!important;float:none!important;width:auto!important;
    height:auto!important;text-align:start!important;margin:0!important;
    padding:0!important;background:none!important
}
.tg-footer .links_item_footer ul,.tg-footer .links_item_footer li{
    display:block!important;float:none!important;width:auto!important;
    height:auto!important;list-style:none!important;background:none!important;
    margin:0!important;padding:0!important
}
.tg-footer .links_item_footer a{
    display:block!important;float:none!important;position:static!important;
    width:auto!important;height:auto!important;min-height:0!important;
    padding:4px 0!important;margin:0!important;background:none!important;
    border:0!important;text-align:start!important;line-height:1.8;
    font-size:12px;color:#6a7a90
}
.tg-footer .links_item_footer a:hover{color:#17263c}
.tg-footer .copy_right{clear:both;text-align:center!important;padding-top:20px}
@media(max-width:600px){
    .tg-footer-links{grid-template-columns:repeat(2,minmax(0,1fr));gap:22px}
    .tg-quick-card strong{font-size:14px}
}
@media(max-width:360px){
    .tg-footer-links{grid-template-columns:1fr}
}


/* Persistent account balance v2 */
.tg-topbar{
    position:sticky!important;top:0;z-index:50;
    box-shadow:0 2px 10px #17263c04
}
.tg-topbar-actions{gap:16px}
.tg-wallet{
    display:flex;align-items:center;gap:10px;flex-shrink:0;
    padding:8px 13px;border:1px solid #f1df9c;border-radius:11px;
    background:#fff9e3;color:#17263c;line-height:1.4
}
.tg-wallet-amount{display:flex;flex-direction:column;gap:2px}
.tg-wallet-amount small{font-size:10px;color:#7b6a38}
.tg-wallet-amount strong{font-size:18px;font-weight:700;letter-spacing:.2px}
.tg-wallet-unit{font-size:11px;color:#7b6a38;align-self:flex-end;padding-bottom:3px}
.tg-wallet-topup{
    font-size:11px;font-weight:600;border-inline-start:1px solid #e8d899;
    padding-inline-start:11px;margin-inline-start:2px;white-space:nowrap
}
.tg-wallet-topup:hover{text-decoration:underline}
@media(max-width:1100px) and (min-width:851px){
    .tg-topbar-heading>span{display:none}
    .tg-topbar-actions{gap:11px}
    .tg-wallet{gap:7px;padding:7px 10px}
    .tg-wallet-amount strong{font-size:16px}
}
@media(max-width:850px){
    .tg-topbar{
        display:grid;grid-template-columns:auto minmax(0,1fr);
        gap:12px 16px;padding:13px 18px
    }
    .tg-topbar-heading{display:none!important}
    .tg-topbar-actions{display:contents}
    .tg-menu-toggle{grid-column:1;grid-row:1;justify-self:start}
    .tg-account{grid-column:2;grid-row:1;justify-self:end}
    .tg-login-link{grid-column:2;grid-row:1;justify-self:end}
    .tg-language{grid-column:1;grid-row:2;justify-self:start}
    .tg-wallet{grid-column:2;grid-row:2;justify-self:end;padding:7px 10px;gap:8px}
    .tg-wallet-amount strong{font-size:16px}
    .tg-wallet-topup{font-size:10px;padding-inline-start:8px}
}
@media(max-width:360px){
    .tg-wallet-unit{display:none}
    .tg-wallet{gap:6px}
    .tg-wallet-topup{padding-inline-start:6px}
}


/* tg-workspace-cleanup-v1 */
/* Keep the wallet in the top bar and one main heading per workspace page. */
body.tg-portal:not(.tg-marketing) .tg-account-stats,
body.tg-portal:not(.tg-marketing) .tg-page-heading .tg-eyebrow,
body.tg-portal:not(.tg-marketing) .tg-topbar-heading>span,
body.tg-portal:not(.tg-marketing) .tg-contacts-intro .tg-contacts-eyebrow,
body.tg-portal:not(.tg-marketing) .tg-contacts-intro h2{
    display:none!important
}
body.tg-portal:not(.tg-marketing) .tg-contacts-intro{
    margin:0 0 16px!important;padding:0!important
}
body.tg-portal:not(.tg-marketing) .tg-contacts-intro p{
    margin:0!important;font-size:14px;line-height:1.8;color:#60718a
}
.tg-contacts .tg-contacts-actions{
    display:flex;flex-wrap:wrap;gap:8px;align-items:center
}
.tg-contacts .tg-contacts-actions button{
    min-height:40px;padding:9px 14px!important;line-height:1.5!important;
    font-size:13px!important;white-space:nowrap;cursor:pointer
}
.tg-contacts .tg-contacts-actions button:disabled{
    opacity:.45;cursor:not-allowed
}
.tg-contacts .tg-contacts-actions .tg-grid-delete-action{
    color:#a82424!important;background:#fff4f4!important;
    border-color:#edcaca!important
}
.tg-contacts .tg-grid-edit-status{
    margin:0 0 14px;padding:11px 14px;border:1px solid #edd479;
    border-radius:8px;background:#fff8dc;color:#594500;font-size:13px
}
.tg-contacts .tg-grid-proxied-control{
    display:none!important
}
.tg-contacts .ui-jqgrid .ui-jqgrid-htable th{
    height:46px!important;vertical-align:middle!important;
    padding-top:6px!important;padding-bottom:6px!important
}
.tg-contacts .ui-jqgrid .ui-jqgrid-htable th>div{
    height:auto!important;min-height:24px;line-height:24px!important;
    padding-top:0!important;padding-bottom:0!important
}
.tg-contacts .ui-jqgrid .ui-jqgrid-htable th input[type=checkbox]{
    display:inline-block!important;position:static!important;
    width:17px!important;height:17px!important;min-height:17px!important;
    margin:3px!important;padding:0!important;vertical-align:middle!important;
    box-sizing:border-box!important;transform:none!important
}
.tg-contacts .ui-jqgrid .ui-jqgrid-titlebar,
.tg-contacts .ui-jqgrid .ui-jqgrid-titlebar .ui-jqgrid-title{
    color:#314760!important;text-shadow:none!important;
    font-weight:600!important
}
/* Dark footer: readable headings, links and credits. */
body.tg-portal .tg-footer .title_item_footer,
body.tg-portal .tg-footer .tm-footer-links strong{
    color:#f2f5fa!important
}
body.tg-portal .tg-footer .links_item_footer a{
    color:#d2ddeb!important
}
body.tg-portal .tg-footer .links_item_footer a:hover{
    color:#ffcc06!important
}
body.tg-portal .tg-footer .copy_right,
body.tg-portal .tg-footer .copy_right p,
body.tg-portal .tg-footer .copy_right a{
    color:#aebfd2!important
}
@media(max-width:700px){
    .tg-contacts .tg-contacts-section-head{
        flex-direction:column;align-items:stretch!important;gap:14px
    }
    .tg-contacts .tg-contacts-actions{
        justify-content:flex-start!important
    }
    .tg-contacts .tg-contacts-actions button{
        min-height:42px;font-size:12px!important
    }
}
