/* Mobile-first YPA notification center: zero CSS margin properties. */
.bottombar a.ypa-notifications-link{position:relative;overflow:visible;isolation:isolate;}
.ypa-notif-badge{position:absolute;z-index:3;top:5px;left:calc(50% + 5px);min-width:17px;height:17px;display:flex;align-items:center;justify-content:center;padding:1px 4px;border:2px solid #fff;border-radius:99px;background:#d92135;color:#fff!important;font-family:system-ui,sans-serif;font-size:9px;font-weight:850;line-height:1;box-shadow:0 1px 4px #8c15284a;white-space:nowrap;pointer-events:none;}
.ypa-notif-badge[hidden]{display:none!important;}
.ypa-notifications-page{--yn-ink:#253246;--yn-sub:#64748b;--yn-border:#e2e8f0;box-sizing:border-box;display:flex;flex-direction:column;gap:10px;padding:14px 12px 95px;width:100%;min-width:0;max-width:100%;color:var(--yn-ink);background:#f6f8fb;overflow-x:hidden;font-size:13px;}
.ypa-notifications-page *{box-sizing:border-box;min-width:0;}
.ypa-notif-header{display:flex;align-items:center;gap:12px;padding:4px 2px 10px;}
.ypa-notif-header-icon{flex:0 0 42px;width:42px;height:42px;border-radius:13px;background:#e9f1fc;color:#3568aa;display:grid;place-items:center;font-size:19px;}
.ypa-notif-header>div:last-child{display:flex;flex-direction:column;gap:3px;}
.ypa-notif-header small{font-size:10px;color:#49749d;font-weight:850;letter-spacing:.07em;}
.ypa-notif-header h1{font-size:20px;font-weight:850;line-height:1.15;}
.ypa-notif-header p{font-size:11px;color:var(--yn-sub);}
.ypa-notif-item{display:flex;gap:10px;align-items:flex-start;padding:13px 11px;border:1px solid #c9d7eb;border-radius:13px;background:#fff;box-shadow:0 2px 8px #202c4210;}
.ypa-notif-item.is-read{border-color:var(--yn-border);background:#fafbfd;box-shadow:none;}
.ypa-notif-item-icon{display:grid;place-items:center;flex:0 0 34px;width:34px;height:34px;border-radius:10px;color:#2e67b3;background:#eaf2ff;font-size:15px;}
.ypa-notif-item.is-read .ypa-notif-item-icon{color:#768596;background:#e9eef4;}
.ypa-notif-item-content{display:flex;flex:1;flex-direction:column;align-items:flex-start;gap:6px;overflow-wrap:anywhere;}
.ypa-notif-title{display:flex;gap:7px;align-items:center;width:100%;}
.ypa-notif-title strong{font-size:13px;line-height:1.3;font-weight:850;}
.ypa-notif-dot{width:8px;height:8px;flex:0 0 8px;border-radius:50%;background:#e22a42;}
.ypa-notif-item-content small{font-size:10px;color:var(--yn-sub);}
.ypa-notif-item-content p{font-size:12px;line-height:1.5;color:#526175;}
.ypa-notif-actions{width:100%;display:flex;gap:7px;flex-wrap:wrap;align-items:center;padding-top:3px;}
.ypa-notif-actions a,.ypa-notif-actions button{display:inline-flex;align-items:center;justify-content:center;gap:5px;min-height:34px;padding:8px 10px;border-radius:9px;font:inherit;font-size:11px;font-weight:800;text-decoration:none;cursor:pointer;}
.ypa-notif-actions a{background:#eaf2fd;color:#225d9b;border:1px solid #d0e1f5;}
.ypa-notif-actions button{border:1px solid #d8e0eb;color:#34475d;background:#fff;}
.ypa-notif-actions button:disabled{opacity:.5;cursor:wait;}
.ypa-notif-section-heading{display:flex;flex-direction:column;gap:3px;padding:13px 2px 3px;}
.ypa-notif-section-heading h2{font-size:14px;font-weight:850;}
.ypa-notif-section-heading span{font-size:11px;color:var(--yn-sub);}
.ypa-notif-empty{display:flex;flex-direction:column;align-items:center;gap:9px;padding:34px 18px;border:1px dashed #cfd9e5;border-radius:14px;background:#fff;color:var(--yn-sub);text-align:center;}
.ypa-notif-empty>i{font-size:25px;color:#8da2bb;}
.ypa-notif-empty strong{font-size:13px;color:#3d5064;}
.ypa-notif-empty span{font-size:11px;}
.ypa-notif-error{padding:12px;border-radius:11px;background:#fff0f0;color:#9c3333;font-size:12px;}
@media(max-width:350px){.ypa-notifications-page{padding-inline:9px;}.ypa-notif-item{padding:10px 9px;gap:8px;}.ypa-notif-actions a,.ypa-notif-actions button{font-size:10px;padding:7px 8px;}}
@media(min-width:768px){.ypa-notifications-page{padding:22px 24px 100px;gap:14px;}.ypa-notif-item{padding:16px;}.ypa-notif-header h1{font-size:23px;}}

/* YPA admin composer, avvisi, counters. Mobile first. No margin declarations. */
.home-grid a{position:relative;}
.home-grid a .ypa-warning-home-badge{position:absolute;top:6px;right:7px;min-width:22px;height:22px;padding:2px 6px;display:flex;align-items:center;justify-content:center;border-radius:99px;background:#d92135;color:#fff;font:800 11px/1 system-ui,sans-serif;box-shadow:0 2px 5px #af1a343b;}
.ypa-send-page,.ypa-messages-page{box-sizing:border-box;width:100%;min-width:0;display:flex;flex-direction:column;gap:12px;padding:12px 11px 90px;background:#f6f8fb;color:#233347;font-size:13px;overflow-x:hidden;}
.ypa-send-page *,.ypa-messages-page *{box-sizing:border-box;min-width:0;}
.ypa-send-header,.ypa-messages-heading{display:flex;align-items:center;gap:10px;padding:8px 3px;}
.ypa-send-header>div,.ypa-messages-heading>div{display:flex;flex-direction:column;gap:3px;flex:1;}
.ypa-send-header h1,.ypa-messages-heading h1{font-size:21px;font-weight:850;line-height:1.2;}
.ypa-send-header small,.ypa-messages-heading small{font-size:10px;color:#48729e;font-weight:850;letter-spacing:.065em;}
.ypa-send-header p,.ypa-messages-heading p{font-size:11px;color:#728096;}
.ypa-send-back,.ypa-send-heading-icon,.ypa-messages-heading>i{flex:0 0 36px;width:36px;height:36px;display:grid;place-items:center;border-radius:11px;background:#e9f0fa;color:#315f95;font-size:16px;text-decoration:none;}
.ypa-send-heading-icon{background:#e2ecf9;}
.ypa-messages-heading>i{flex-basis:43px;width:43px;height:43px;font-size:19px;}
.ypa-send-page form{display:flex;flex-direction:column;gap:12px;}
.ypa-send-panel{display:flex;flex-direction:column;gap:11px;border:1px solid #e1e7f0;border-radius:15px;background:#fff;padding:14px 12px;box-shadow:0 2px 8px #23334e0b;}
.ypa-send-panel>label:not(.ypa-send-file),.ypa-send-label{font-size:13px;font-weight:800;color:#293e57;}
.ypa-send-scopes{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px;}
.ypa-send-scope{position:relative;display:block;cursor:pointer;}
.ypa-send-scope input{position:absolute;opacity:0;inset:0;width:100%;height:100%;cursor:pointer;}
.ypa-send-scope>span{display:flex;min-height:94px;flex-direction:column;align-items:center;justify-content:center;gap:6px;padding:9px 5px;border:1px solid #d9e3f0;border-radius:12px;background:#f9fbfe;text-align:center;color:#334962;}
.ypa-send-scope i{font-size:20px;color:#6682a5;}
.ypa-send-scope b{font-size:11px;line-height:1.2;}
.ypa-send-scope small{font-size:9px;color:#697c91;}
.ypa-send-scope input:checked+span{border-color:#3574bd;background:#eaf3ff;box-shadow:0 0 0 1px #3574bd23;}
.ypa-send-scope input:checked+span i{color:#2d69b3;}
.ypa-send-scope input:focus-visible+span{outline:2px solid #235ca6;outline-offset:2px;}
.ypa-send-choice{display:flex;flex-direction:column;gap:8px;padding-top:5px;}
.ypa-send-choice[hidden]{display:none;}
.ypa-send-choice>label{font-weight:800;}
.ypa-send-page input:not([type=radio]):not([type=checkbox]):not([type=file]),.ypa-send-page select,.ypa-send-page textarea{display:block;width:100%;min-height:42px;padding:10px 11px;border:1px solid #cbd6e4;border-radius:10px;background:#fff;font:inherit;font-size:13px;color:#22354c;outline:none;}
.ypa-send-page textarea{min-height:142px;resize:vertical;line-height:1.55;}
.ypa-send-page input:focus,.ypa-send-page textarea:focus,.ypa-send-page select:focus{border-color:#4084d4;box-shadow:0 0 0 2px #4084d42b;}
.ypa-send-selected{display:flex;flex-wrap:wrap;align-items:center;gap:6px;font-size:11px;color:#63748a;}
.ypa-send-chip{padding:5px 8px;background:#e9f2fe;color:#255d99;border:1px solid #c3ddf7;border-radius:20px;font:750 11px system-ui,sans-serif;cursor:pointer;}
.ypa-send-people{max-height:252px;overflow-y:auto;display:flex;flex-direction:column;gap:4px;padding:5px;border:1px solid #e1e7f0;border-radius:11px;background:#f9fbfd;}
.ypa-send-person{display:flex;align-items:center;gap:9px;padding:9px;border:1px solid #e7edf4;border-radius:9px;background:#fff;cursor:pointer;}
.ypa-send-person input{width:17px;height:17px;flex:0 0 17px;accent-color:#2d71b9;}
.ypa-send-person span{display:flex;flex-direction:column;gap:3px;overflow-wrap:anywhere;}
.ypa-send-person strong{font-size:12px;}
.ypa-send-person small{font-size:10px;color:#68778c;}
.ypa-send-file{display:flex;gap:9px;align-items:center;justify-content:center;padding:12px;border:1px dashed #7eafdc;border-radius:11px;background:#edf6ff;color:#275c96;font-size:12px;font-weight:850;cursor:pointer;}
.ypa-send-file small{color:#71869b;font-weight:500;}
.ypa-send-file-info{font-size:10px;overflow-wrap:anywhere;color:#64748b;}
.ypa-send-last>p{display:flex;align-items:flex-start;gap:7px;color:#607389;font-size:11px;line-height:1.55;}
.ypa-send-last>button{display:flex;align-items:center;justify-content:center;gap:9px;width:100%;min-height:46px;padding:11px;border:0;border-radius:11px;background:#2f6db2;color:#fff;font-size:13px;font-weight:850;cursor:pointer;}
.ypa-send-last>button:disabled{opacity:.55;cursor:wait;}
.ypa-send-last [data-ypa-feedback]{font-size:12px;color:#2e6946;overflow-wrap:anywhere;}
.ypa-messages-certificate{display:flex;flex-direction:column;gap:8px;}
.ypa-message-item{display:flex;flex-direction:column;gap:9px;border:1px solid #cbd9e9;border-radius:14px;background:#fff;padding:13px 12px;box-shadow:0 2px 8px #222e4310;overflow-wrap:anywhere;}
.ypa-message-item.is-read{background:#fbfcfd;border-color:#e1e7ef;box-shadow:none;}
.ypa-message-title{display:flex;align-items:flex-start;gap:6px;justify-content:space-between;}
.ypa-message-title strong{font-size:14px;line-height:1.35;}
.ypa-message-dot{flex:0 0 8px;width:8px;height:8px;border-radius:99px;background:#d92135;}
.ypa-message-item>small{font-size:10px;color:#788599;}
.ypa-message-text{font-size:12px;line-height:1.65;color:#40516a;overflow-wrap:anywhere;white-space:normal;}
.ypa-message-files{display:flex;flex-direction:column;gap:7px;}
.ypa-message-files button{display:flex;align-items:center;gap:7px;padding:10px;border:1px solid #d3e3f5;border-radius:9px;background:#edf5fd;color:#285b90;font:700 11px system-ui,sans-serif;text-align:left;overflow-wrap:anywhere;cursor:pointer;}
.ypa-message-read{align-self:flex-start;border:1px solid #cddbe9;border-radius:9px;background:#fff;color:#345c85;min-height:35px;padding:8px 11px;font:800 11px system-ui,sans-serif;cursor:pointer;}
.ypa-message-read:disabled,.ypa-message-files button:disabled{opacity:.55;}
.ypa-msg-empty{display:flex;flex-direction:column;gap:7px;align-items:center;justify-content:center;padding:28px 16px;border:1px dashed #d6dee7;border-radius:13px;background:#fff;color:#63758a;text-align:center;}
.ypa-msg-empty i{font-size:26px;}
.ypa-msg-empty strong{color:#344965;}
.ypa-messages-error{padding:12px;border-radius:11px;background:#fff0f0;color:#a83030;}
@media (max-width:350px){.ypa-send-page,.ypa-messages-page{padding-inline:8px;}.ypa-send-header{gap:6px;}.ypa-send-scope>span{min-height:86px;padding:7px 3px;}.ypa-send-scope b{font-size:10px;}.ypa-send-scope small{font-size:8px;}}
@media (min-width:768px){.ypa-send-page,.ypa-messages-page{max-width:920px;padding:23px 24px 100px;}.ypa-send-header h1,.ypa-messages-heading h1{font-size:25px;}.ypa-send-scopes{max-width:650px;}}

/* Inline Avvisi attachments and sender previews — mobile first, no margin properties. */
.ypa-message-files{display:flex;flex-direction:column;gap:11px;width:100%;}
.ypa-message-attachment,.ypa-send-file-preview{width:100%;min-width:0;display:flex;flex-direction:column;gap:9px;padding:10px;border:1px solid #d7e2f1;border-radius:12px;background:#f7faff;}
.ypa-message-attachment-heading{display:flex;align-items:center;gap:10px;}
.ypa-message-attachment-heading>i{display:grid;place-items:center;flex:0 0 35px;width:35px;height:35px;border-radius:9px;color:#2c629e;background:#e5effb;font-size:18px;}
.ypa-message-attachment-heading>div{display:flex;flex-direction:column;gap:3px;min-width:0;overflow-wrap:anywhere;}
.ypa-message-attachment-heading strong,.ypa-send-file-preview>strong{font-size:12px;color:#284463;overflow-wrap:anywhere;}
.ypa-message-attachment-heading small{font-size:10px;color:#657a91;}
.ypa-attachment-preview,.ypa-send-file-previews{display:flex;flex-direction:column;gap:8px;min-width:0;width:100%;}
.ypa-attachment-preview[hidden]{display:none;}
.ypa-attachment-loading,.ypa-attachment-error{min-height:62px;display:flex;gap:8px;align-items:center;justify-content:center;text-align:center;padding:10px;background:#fff;border:1px dashed #d0dfed;border-radius:9px;color:#526b89;font-size:11px;}
.ypa-attachment-error{color:#a23a3a;}
.ypa-attachment-preview>button{align-self:flex-start;border:1px solid #a9c5e3;background:#fff;color:#2a629e;border-radius:8px;padding:8px 12px;font-size:11px;cursor:pointer;}
.ypa-inline-image{display:block;width:100%;height:auto;max-height:420px;object-fit:contain;border-radius:9px;background:#e9edf4;border:1px solid #d9e2ef;padding:10px;}
.ypa-inline-pdf{display:block;width:100%;height:390px;min-height:270px;border:1px solid #cfddeb;border-radius:9px;background:#fff;}
.ypa-inline-pdf-fallback{font-size:10px;color:#61788f;line-height:1.45;}
.ypa-inline-pdf-open,.ypa-send-file-preview>a{display:inline-flex;align-items:center;justify-content:center;align-self:flex-start;gap:6px;padding:8px 11px;border:1px solid #bbd4f0;border-radius:8px;background:#fff;color:#2c6095;text-decoration:none;font-size:11px;font-weight:800;}
.ypa-attachment-actions{display:grid;grid-template-columns:repeat(1,minmax(0,1fr));gap:8px;}
.ypa-message-files .ypa-attachment-actions button{min-height:38px;display:inline-flex;align-items:center;justify-content:center;gap:7px;padding:9px 7px;border:1px solid #b9d1ee;border-radius:9px;background:#e8f2fd;color:#285e9b;font:800 11px system-ui,sans-serif;cursor:pointer;text-align:center;}
.ypa-message-files .ypa-attachment-actions button:disabled{opacity:.5;cursor:wait;}
.ypa-send-file-previews:empty{display:none;}
@media(max-width:350px){.ypa-inline-pdf{height:295px;min-height:250px;}.ypa-attachment-actions{gap:5px;}.ypa-message-attachment{padding:8px;}}
@media(min-width:768px){.ypa-inline-pdf{height:500px;}.ypa-inline-image{max-height:580px;}}
