* { margin: 0; padding: 0; box-sizing: border-box; font-family: "Roboto", "Noto Sans", sans-serif; transition-timing-function: cubic-bezier(.4,0,.2,1); } /* TODO - normalize text size - put all colors in variables - checklists using ::marker? - links - CSS scroll snap for columns - https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_scroll_snap - box-decoration-break: clone; -webkit-box-decoration-break: clone; - overscroll-behavior: contain; - user-select: text; */ :root, ::backdrop { --bg-color: #FFF; --page-bg-color: #EEE; --text-color: rgba(0,0,0,.87); --error-triple: 176, 0, 32; --error-color: rgb(var(--error-triple)); --icon-opacity-active: .87; --icon-opacity-inactive: .6; --icon-opacity-disabled: .38; --icon-inactive-filter: brightness(0); --icon-checkbox-active-filter: brightness(1); --icon-add-hover-filter: brightness(1); --icon-menu-hover-filter: brightness(1); --icon-search-hover-filter: brightness(1); --icon-window-hover-filter: brightness(1); --menu-button-hover-bg-color: #FBBC04; --button-hover-bg-color: #FFF; --button-hover-shadow: 0 2px 16px rgba(0,0,0,.1), 0 2px 4px rgba(0,0,0,.2); --fab-bg: #FFF; --fab-shadow: 0 2px 12px rgba(0,0,0,.15), 0 2px 6px rgba(0,0,0,.2); --fab-shadow-hover: 0 4px 16px rgba(0,0,0,.2), 0 3px 6px rgba(0,0,0,.3); --toolbar-shadow-mobile: 0 8px 8px 8px rgba(0,0,0,.2); --toolbar-hide-distance-mobile: calc(-56px - 8px); --toolbar-button-hover-bg-mobile: rgba(0,0,0,.1); } /*@media (prefers-color-scheme: dark) { :root, ::backdrop { --bg-color: #000; --page-bg-color: #000; --text-color: rgba(255,255,255,.87); --error-triple: 245, 0, 45; --error-color: rgb(var(--error-triple)); --icon-opacity-active: .87; --icon-opacity-inactive: .6; --icon-opacity-disabled: .38; --icon-inactive-filter: brightness(0) invert(1) hue-rotate(180deg); --icon-add-hover-filter: brightness(1.4) invert(.1) hue-rotate(0); --icon-menu-hover-filter: brightness(1) invert(1) hue-rotate(180deg); --icon-search-hover-filter: brightness(1) invert(1) hue-rotate(180deg); --icon-window-hover-filter: brightness(.75) invert(1) hue-rotate(180deg); --menu-button-hover-bg-color: #FBBC04; --button-hover-bg-color: #181818; --button-hover-shadow: 0 0 0 transparent; --fab-bg: #333; --fab-shadow: 0 2px 12px rgba(0,0,0,.2), 0 2px 6px rgba(0,0,0,.24); --fab-shadow-hover: 0 2px 12px rgba(0,0,0,.2), 0 2px 6px rgba(0,0,0,.24); --toolbar-shadow-mobile: 0 8px 8px 8px #000, 0 56px 56px -56px rgba(255,255,255,.25) inset; --toolbar-hide-distance-mobile: calc(-56px - 8px); --toolbar-button-hover-bg-mobile: rgba(255,255,255,.1); }}*/ html { background: var(--page-bg-color); color: var(--text-color); overscroll-behavior: contain; } body, dialog { /* TODO */ user-select: none; -webkit-touch-callout: none; -webkit-tap-highlight-color: transparent; } #toolbar { position: fixed; font-size: 0; } #toolbar > * { font-size: 16px; text-align: center; } .toolbar-btn { height: 48px; width: 48px; } .toolbar-btn, .toolbar-fab { position: relative; border-radius: 100%; background: transparent; border: none; outline: none; } .toolbar-btn:not(#conflict-btn)::after, .toolbar-fab::after { content: ""; display: block; height: 24px; width: 24px; background-image: url("icons.svg"); filter: var(--icon-inactive-filter); opacity: var(--icon-opacity-active); position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%); } #menu-btn::after { background-position: 0 0; } #window-btn::after { background-position: -24px 0; } #search-btn::after { background-position: -48px 0; } #add-btn::after { background-position: -72px 0; } #conflict-btn { display: none; vertical-align: bottom; } #conflict-btn::after { content: ""; position: absolute; top: 50%; left: 50%; display: block; height: 8px; width: 8px; border-radius: 4px; background: rgba(var(--error-triple), .8); transform: translate(-50%,-50%); } @media (hover:hover) { .toolbar-btn, .toolbar-fab { cursor: pointer; transition: background-color .2s, box-shadow .2s; } .toolbar-btn:not(#conflict-btn)::after, .toolbar-fab::after { transition: opacity .1s, filter .1s; filter: var(--icon-inactive-filter); } .toolbar-btn:not(#conflict-btn):hover::after, .toolbar-fab:hover::after { opacity: 1; } #menu-btn:hover::after { filter: var(--icon-menu-hover-filter); } #window-btn:hover::after { filter: var(--icon-window-hover-filter); } #search-btn:hover::after { filter: var(--icon-search-hover-filter); } #add-btn:hover::after { filter: var(--icon-add-hover-filter); } #conflict-btn::after { transition: box-shadow .1s; } #conflict-btn:hover::after { box-shadow: 0 0 0 4px rgba(var(--error-triple),.25); } } @media (hover:hover) and (min-width:601px) { .notes-column { padding: 8px 80px 16px; } #toolbar { top: 16px; left: 50%; transform: translate(-50%,0); width: 100%; max-width: calc(7in + 16px); pointer-events: none; } #toolbar > * { pointer-events: auto; } .toolbar-fab { height: 48px; width: 48px; } .toolbar-btn, .toolbar-fab { display: block; margin: 0 16px; } .toolbar-btn:not(#conflict-btn):hover, .toolbar-fab:hover { background-color: var(--button-hover-bg-color); box-shadow: var(--button-hover-shadow); } .toolbar-btn:not(#conflict-btn)::after, .toolbar-fab::after { opacity: var(--icon-opacity-inactive) } .toolbar-btn:not(#conflict-btn):hover::after, .toolbar-fab:hover::after { opacity: var(--icon-opacity-active) } #menu-btn:hover { background-color: var(--menu-button-hover-bg-color) !important; } #search-btn { position: absolute; top: 0; right: 0; } #add-btn { position: absolute; top: 48px; right: 0; } #conflict-btn { height: 42px; } #conflict-btn.show { display: block; } } @media (hover:none), (max-width:600px) { .notes-column { padding: 0 16px 16px; } #toolbar { bottom: 0; left: 0; right: 0; width: 100%; box-shadow: var(--toolbar-shadow-mobile); padding: 0 4px; background: var(--bg-color); transition: bottom .25s; /* reentrance speed */ } .toolbar-btn { display: inline-block; } .toolbar-fab { position: absolute; display: block; right: 16px; top: -28px; width: 56px; height: 56px; box-shadow: var(--fab-shadow); background: var(--fab-bg); transition: top .25s; } #conflict-btn { width: 36px; } #conflict-btn.show { display: inline-block; } #toolbar.hide { bottom: var(--toolbar-hide-distance-mobile); transition: bottom .2s; /* exit speed */ } #toolbar.hide .toolbar-fab { top: calc(var(--toolbar-hide-distance-mobile) - 16px); transition: top .2s; } @media (orientation:portrait) { .toolbar-btn { margin: 4px 0; } } @media (orientation:landscape) { .toolbar-btn { margin: 0; } } } @media (hover:hover) and (max-width:600px) { .toolbar-btn:not(#conflict-btn)::before { content: ""; display: block; position: absolute; top: 50%; left: 50%; height: 40px; width: 40px; border-radius: 20px; transform: translate(-50%,-50%); transition: background-color .2s; } .toolbar-btn:not(#conflict-btn):hover::before { background-color: var(--toolbar-button-hover-bg-mobile); } #menu-btn:hover::before { background-color: var(--menu-button-hover-bg-color) !important; } .toolbar-fab { transition: top .25s, box-shadow .2s; } #toolbar.hide .toolbar-fab { transition: top .2s, box-shadow .2s; } .toolbar-fab:hover { box-shadow: var(--fab-shadow-hover); } #add-btn::after { transition: opacity .15s, filter .15s, transform .2s; } #add-btn:hover::after { filter: var(--icon-add-hover-filter); transform: translate(-50%,-50%) scale(1.25); } } .logo { font-weight: 500; word-spacing: -.15em; } .logo-icon { vertical-align: -.45em; height: 1.6em; } #sign-in-dialog { margin: auto; width: auto; max-width: min(5.5in, 100vw - 32px); outline: none; border: none; border-radius: 24px; box-shadow: 0 2px 16px rgba(0,0,0,.05), 0 2px 4px rgba(0,0,0,.1); transition: box-shadow .2s; } #sign-in-dialog::after { content: ""; position: absolute; inset: 0; box-shadow: 0 0 0 1px rgba(255,255,255,.2) inset; border-radius: 24px; pointer-events: none; transition: box-shadow .2s; } #sign-in-dialog::backdrop { background: var(--page-bg-color); } #sign-in-form { display: block; padding: 16px 16px 40px; & .logo { margin: 16px 0; padding: .1em .3em .1em 0; font-size: min(48px, 12vw); text-align: center; } & .error-message { text-align: center; color: var(--error-color); } & input[type=text], & input[type=password], & label, & button { display: block; width: 100%; max-width: 3.5in; margin: 12px auto; font-size: inherit; letter-spacing: .3px; color: var(--text-color); border-radius: 16px; } & input[type=text], & input[type=password], & button { padding: 12px 18px; outline: 0; } & input[type=text], & input[type=password] { position: relative; background-color: #FFF; border: 1px solid #FFF; border-bottom: 1px solid rgba(0,0,0,.15); box-shadow: 0 2px 1px -1px rgba(0,0,0,.1); transition: border .2s, box-shadow .2s, opacity .2s; } & input[type=text]:hover:not(:disabled), & input[type=password]:hover:not(:disabled), & input[type=text]:focus, & input[type=password]:focus { border: 1px solid rgba(0,0,0,.07); border-bottom: 1px solid rgba(0,0,0,.18); box-shadow: 0 2px 16px rgba(0,0,0,.05), 0 2px 4px rgba(0,0,0,.15); } & input[type=text]::placeholder, & input[type=password]::placeholder { color: rgba(0,0,0,.6); } & input[type=text]:autofill, & input[type=password]:autofill { background-color: rgb(232,240,254); border: 1px solid rgb(179,207,255); } & input[type=text].error, & input[type=password].error { background-color: rgb(254,232,232); border: 1px solid rgb(255,191,191); } & input[type=text].error:focus, & input[type=password].error:focus { box-shadow: 0 2px 16px rgba(0,0,0,.05), 0 2px 4px rgba(0,0,0,.15), 0 0 1px 2px rgb(255,191,191) inset; } & label { width: fit-content; padding: 8px 12px 8px 8px; text-align: center; cursor: pointer; transition: background-color .2s, opacity .2s; } & label:focus-within:has(:focus-visible) { background-color: rgb(232,240,254); text-align: center; cursor: pointer; } & input[type=checkbox] { display: inline-block; height: 0; width: 0; opacity: 0; } .checkbox-icon { display: inline-block; height: 24px; width: 24px; vertical-align: -.36em; background-image: url("icons.svg"); background-position: -24px -48px; filter: var(--icon-inactive-filter); opacity: var(--icon-opacity-inactive); } input[type=checkbox]:checked + .checkbox-icon { background-position: 0 -48px; filter: var(--icon-checkbox-active-filter); opacity: var(--icon-opacity-active); } & button { position: relative; font-weight: 500; background-color: rgba(0,0,0,.06); border: none; cursor: pointer; transition: background-color .2s, box-shadow .2s; } & button:hover, & button:focus, &.loading button { background-color: #FBBC04; } & button:focus-visible { box-shadow: 0 0 0 4px rgba(251,188,4,.4); } & input + button { margin-top: 32px; } &.loading button { color: transparent; } & button .loading-spinner { inset: 50%; transform: translate(-50%,calc(-50% - 1em)); display: none; } &.loading button .loading-spinner { display: inline-block; } & .loading-spinner, & .loading-spinner::before, & .loading-spinner::after { position: absolute; border-radius: 50%; width: .7em; height: .7em; animation-fill-mode: both; animation: loading-spinner 1.8s infinite ease-in-out; } & .loading-spinner { animation-delay: -0.16s; } & .loading-spinner::before, & .loading-spinner::after { content: ''; top: 0; } & .loading-spinner::before { left: -1.3em; animation-delay: -0.32s; } & .loading-spinner::after { left: 1.3em; } &.loading input, &.loading label { opacity: .5; } } @keyframes loading-spinner { 0%, 80%, 100% { box-shadow: 0 1em 0 -1.3em #fff; } 40% { box-shadow: 0 1em 0 0 #fff; } } .notes-column { overflow-y: auto; } /* TODO :target? */ .card-shadow { position: relative; margin: 16px auto; max-width: 5.5in; border-radius: 24px; box-shadow: 0 2px 16px rgba(0,0,0,.05), 0 2px 4px rgba(0,0,0,.1); transition: box-shadow .2s; } .card-shadow:hover, .card-shadow:focus-within { box-shadow: 0 2px 16px rgba(0,0,0,.15), 0 2px 4px rgba(0,0,0,.15); } .card-shadow::after { content: ""; position: absolute; inset: 0; box-shadow: 0 0 0 1px rgba(255,255,255,.2) inset; border-radius: 24px; pointer-events: none; transition: box-shadow .2s; } .card-shadow:hover::after, .card-shadow:focus-within::after { box-shadow: 0 0 0 2px rgba(255,255,255,.25) inset; } .card { /*padding-bottom: 16px;*/ border-radius: 24px; background-color: var(--bg-color); color: var(--text-color); overflow: hidden; } .card > textarea { /* TODO */ display: block; width: 100%; padding: 16px 24px; border: none; resize: none; outline: none; font-size: 16px; line-height: 24px; letter-spacing: .3px; background: transparent; color: inherit; }