/* CRCW: "Email here" / "Open in my email app" (crcw_mail_links.class.php) and the compose pages. Loaded after crcw.css. */

/* ---------- The two options ---------- */
.crcw-mailopts { display: inline-flex; flex-wrap: wrap; gap: 4px 6px; vertical-align: middle; }
.crcw-mailopts a { display: inline-block; border: 1px solid var(--line); border-radius: 6px; padding: 2px 9px; font-size: 13px; font-style: normal; line-height: 20px; white-space: nowrap; background: #fff; color: var(--blue-dark) !important; text-decoration: none !important; }
.crcw-mailopts a:hover, .crcw-mailopts a:focus { background: var(--sand); color: var(--navy) !important; border-color: var(--teal); }
.crcw-mailopts a.crcw-mail-here { background: var(--blue); border-color: var(--blue); color: #fff !important; }
.crcw-mailopts a.crcw-mail-here:hover, .crcw-mailopts a.crcw-mail-here:focus { background: var(--blue-dark); color: #fff !important; }
.crcw-mailopts-small a { font-size: 12px; line-height: 17px; padding: 1px 7px; }
.crcw-mailopts.pull-right { max-width: 100%; justify-content: flex-end; }
.roster-date .crcw-mailopts { flex-direction: column; align-items: flex-end; gap: 1px; }
.roster-date .crcw-mailopts a, .roster-date .crcw-mailopts a.crcw-mail-here { border: 0; background: transparent; padding: 0; font-size: 12px !important; font-weight: 400; line-height: 17px; opacity: 1 !important; color: var(--blue-dark) !important; }
.roster-date .crcw-mailopts a.crcw-mail-here { font-weight: 600; }
.roster-date .crcw-mailopts a:hover { text-decoration: underline !important; }
.roster-date .crcw-mailopts .icon-email { display: none; }
#service-personnel h3 .pull-right .crcw-mailopts { margin: 2px 0; }
.crcw-mail-box { margin: 0 0 10px; }
.crcw-mail-box form { display: inline; margin: 0; }
.crcw-mail-addr { overflow-wrap: anywhere; }
@media print { .crcw-mailopts { display: none; } }
@media (max-width: 767px) {
	.crcw-mailopts a { padding: 5px 11px; }
	.roster-date .crcw-mailopts a { padding: 4px 0; }
	.crcw-mailopts-small { display: flex; margin-top: 3px; }
	.group-members-links .crcw-mailopts { margin: 4px 0; }
}

/* ---------- Pages ---------- */
.crcw-compose { max-width: 900px; overflow-wrap: anywhere; }
.crcw-compose [hidden] { display: none !important; }
.crcw-compose .crcw-card { margin: 0 0 14px; max-width: none; }
.crcw-compose h3 { margin-top: 0; }
.crcw-compose h3 small { color: var(--muted); }
.crcw-compose .crcw-small { font-size: 13px; line-height: 1.45; }
.crcw-mailmode { border-radius: 8px; padding: 9px 13px; margin: 4px 0 14px; border: 2px solid; }
.crcw-mailmode-test { background: #fff4d6; border-color: #e0b84f; }
.crcw-mailmode-off { background: #f3e1e0; border-color: #c0504d; }
.crcw-mailmode-live { background: #e4f1e7; border-color: #6fae7e; }
.crcw-chips { list-style: none; margin: 0 0 8px; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; max-height: 300px; overflow-y: auto; }
.crcw-chip { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 0 7px; max-width: 100%; box-sizing: border-box; background: var(--sand); border: 1px solid var(--line); border-radius: 16px; padding: 2px 4px 2px 12px; line-height: 24px; }
.crcw-chip-name { font-weight: 600; }
.crcw-chip-email { color: var(--muted); font-size: 12px; }
.crcw-chip-flag { font-size: 11px; background: #fff4d6; color: #5a4410; border-radius: 8px; padding: 0 7px; line-height: 18px; }
.crcw-chip-why { font-size: 12px; color: #a1423f; }
.crcw-chip-off { background: #f3eeee; border-style: dashed; }
.crcw-chip-off .crcw-chip-name { text-decoration: line-through; font-weight: 400; }
.crcw-chip-x { border: 0; background: transparent; width: 28px; height: 28px; border-radius: 50%; font-size: 18px; line-height: 1; color: var(--muted); cursor: pointer; }
.crcw-chip-x:hover { background: var(--line); color: var(--ink); }
.crcw-compose details { margin: 6px 0; }
.crcw-compose summary { cursor: pointer; color: var(--blue-dark); }
.crcw-compose .crcw-field { display: block; margin: 0 0 14px; padding: 0; border: 0; font-weight: 600; }
.crcw-compose .crcw-field p { margin: 4px 0 0; }
.crcw-compose .crcw-field p, .crcw-compose .crcw-field li, .crcw-compose .crcw-edit { font-weight: 400; }
.crcw-compose .crcw-field > input[type=text], .crcw-compose .crcw-field > select { display: block; width: 100%; max-width: 100%; box-sizing: border-box; height: 34px; }
.crcw-compose .crcw-field > input[type=number] { display: block; width: 110px; }
.crcw-compose input[type=file] { display: block; max-width: 100%; margin: 4px 0; }
.crcw-editor { border: 1px solid #cfc8bb; border-radius: 8px; background: #fff; overflow: hidden; }
.crcw-tools { display: flex; flex-wrap: wrap; gap: 4px; padding: 6px; background: var(--sand); border-bottom: 1px solid var(--line); }
.crcw-tools button, .crcw-tools select { height: 32px; min-width: 34px; margin: 0; padding: 0 9px; border: 1px solid var(--line); border-radius: 6px; background: #fff; color: var(--ink); font-size: 13px; cursor: pointer; }
.crcw-tools select { width: 110px; }
.crcw-tools button:hover { border-color: var(--teal); }
.crcw-edit { min-height: 220px; padding: 12px 14px; font-size: 15px; line-height: 1.55; outline: none; overflow-wrap: anywhere; }
.crcw-edit:focus { box-shadow: inset 0 0 0 2px var(--teal); }
.crcw-edit p { margin: 0 0 12px; }
.crcw-edit h2, .crcw-edit h3 { font-size: 20px; margin: 14px 0 6px; }
.crcw-edit ul, .crcw-edit ol { margin: 0 0 12px; padding-left: 24px; }
.crcw-edit blockquote { border-left: 4px solid var(--teal); margin: 0 0 12px; padding: 2px 14px; }
.crcw-files, .crcw-names, .crcw-maillist, .crcw-rcpts { margin: 4px 0 8px; }
.crcw-files, .crcw-maillist, .crcw-rcpts { list-style: none; padding: 0; }
.crcw-maillist > li, .crcw-rcpts > li { border-bottom: 1px solid var(--line); padding: 8px 0; }
.crcw-rcpts { max-height: 460px; overflow-y: auto; }
.crcw-names { max-height: 260px; overflow-y: auto; }
.crcw-rnote { margin-left: 6px; color: #a1423f; }
.crcw-rnote:empty, .crcw-chip-why:empty, .crcw-chip-email:empty { display: none; }
.crcw-row { display: flex; flex-wrap: wrap; gap: 6px 8px; align-items: center; margin: 6px 0; }
.crcw-row input[type=text], .crcw-row select { margin: 0; flex: 1 1 200px; min-width: 0; max-width: 360px; height: 32px; box-sizing: border-box; }
.crcw-kinds { border: 0; margin: 0 0 12px; padding: 0; }
.crcw-kinds label { margin-bottom: 8px; }
.crcw-preview-head { display: flex; flex-wrap: wrap; gap: 8px; justify-content: space-between; margin-bottom: 8px; }
.crcw-compose .crcw-frame { background: #f5f1ea; border: 1px solid var(--line); border-radius: 8px; overflow-x: auto; text-align: center; }
.crcw-compose .crcw-frame iframe { border: 0; width: 100%; max-width: 100%; display: block; margin: 0 auto; min-height: 120px; }
.crcw-compose .crcw-frame iframe[hidden] { display: none; }
.crcw-facts { display: grid; grid-template-columns: max-content 1fr; gap: 6px 16px; margin: 0; }
.crcw-facts dt { color: var(--muted); font-weight: 600; }
.crcw-facts dd { margin: 0; min-width: 0; }
.crcw-facts + h3 { margin-top: 16px; }
.crcw-facts details { margin: 2px 0; }
.crcw-bar { position: sticky; bottom: 0; z-index: 5; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; background: var(--paper); border-top: 1px solid var(--line); padding: 10px 0; margin: 0; }
.crcw-bar-link { margin-left: auto; }
.crcw-default-submit { position: absolute; width: 1px; height: 1px; padding: 0; border: 0; opacity: 0; overflow: hidden; }
.crcw-stats { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.crcw-stat { display: inline-block; border-radius: 10px; padding: 1px 10px; font-size: 13px; font-weight: 600; line-height: 22px; background: #eceae5; color: var(--muted); font-family: var(--sans); white-space: nowrap; vertical-align: middle; }
.crcw-stat[hidden] { display: none; }
.crcw-stat-sent, .crcw-stat-live { background: #e4f1e7; color: #2f6b40; }
.crcw-stat-queued, .crcw-stat-sending, .crcw-stat-test { background: #fff4d6; color: #5a4410; }
.crcw-stat-failed, .crcw-stat-unknown { background: #f3e1e0; color: #a1423f; }
.crcw-ack { flex: 1 1 100%; background: #fff4d6; border: 1px solid #e0b84f; border-radius: 8px; padding: 8px 12px 8px 34px !important; margin: 0; }
.crcw-subject { font-size: 22px; line-height: 1.3; }
@media (max-width: 767px) {
	.crcw-compose .crcw-edit, .crcw-compose input, .crcw-compose select { font-size: 16px; }
	.crcw-facts { grid-template-columns: 1fr; gap: 0 0; }
	.crcw-facts dd { margin-bottom: 8px; }
	.crcw-bar { position: static; }
	.crcw-bar .btn-primary { flex: 1 1 100%; }
	.crcw-bar-link { margin-left: 0; }
	.crcw-compose .crcw-frame { margin: 0 -6px; }
}
