blog

Log | Files | Refs

md-content.css (4354B)


      1 .md-content h3,
      2 .md-content h4,
      3 .md-content h5,
      4 .md-content h6 {
      5     margin: 24px 0 16px;
      6 }
      7 
      8 .md-content h1 {
      9     margin: 40px auto 32px;
     10     font-size: 40px;
     11 }
     12 
     13 .md-content h2 {
     14     margin: 32px auto 24px;
     15     font-size: 32px;
     16 }
     17 
     18 .md-content h3 {
     19     font-size: 24px;
     20 }
     21 
     22 .md-content h4 {
     23     font-size: 16px;
     24 }
     25 
     26 .md-content h5 {
     27     font-size: 14px;
     28 }
     29 
     30 .md-content h6 {
     31     font-size: 12px;
     32 }
     33 
     34 .md-content a:not(.anchor) {
     35     text-underline-offset: 0.3rem;
     36     text-decoration: underline;
     37 }
     38 
     39 .md-content del {
     40     text-decoration: line-through;
     41 }
     42 
     43 .md-content dl:not(:last-child),
     44 .md-content ol:not(:last-child),
     45 .md-content p:not(:last-child),
     46 .md-content figure:not(:last-child),
     47 .md-content ul:not(:last-child) {
     48     margin-bottom: var(--content-gap);
     49 }
     50 
     51 .md-content ol,
     52 .md-content ul {
     53     padding-inline-start: 1.25rem;
     54 }
     55 
     56 .md-content li {
     57     margin-top: 0.3rem;
     58 }
     59 
     60 .md-content li p {
     61     margin-bottom: 0;
     62 }
     63 
     64 .md-content dl {
     65     display: flex;
     66     flex-wrap: wrap;
     67     margin: 0;
     68 }
     69 
     70 .md-content dt {
     71     width: 25%;
     72     font-weight: 700;
     73 }
     74 
     75 .md-content dd {
     76     width: 75%;
     77     margin-inline-start: 0;
     78     padding-inline-start: 10px;
     79 }
     80 
     81 .md-content dd~dd,
     82 .md-content dt~dt {
     83     margin-top: 10px;
     84 }
     85 
     86 .md-content table {
     87     margin-bottom: var(--content-gap);
     88 }
     89 
     90 .md-content table th,
     91 .md-content table:not(.highlighttable, .highlight table, .gist .highlight) td {
     92     min-width: 80px;
     93     padding: 6px 13px;
     94     line-height: 1.5;
     95     border: 1px solid var(--border);
     96 }
     97 
     98 .md-content table th {
     99     text-align: start;
    100 }
    101 
    102 .md-content table:not(.highlighttable) td code:only-child {
    103     margin: auto 0;
    104 }
    105 
    106 .md-content .highlight table {
    107     border-radius: var(--radius);
    108 }
    109 
    110 .md-content .highlight:not(table) {
    111     margin-bottom: var(--content-gap);
    112     background: var(--code-block-bg) !important;
    113     border-radius: var(--radius);
    114     direction: ltr;
    115 }
    116 
    117 .md-content li>.highlight {
    118     margin-inline-end: 0;
    119 }
    120 
    121 .md-content ul pre {
    122     margin-inline-start: calc(var(--gap) * -2);
    123 }
    124 
    125 .md-content .highlight pre {
    126     margin: 0;
    127 }
    128 
    129 .md-content .highlighttable {
    130     table-layout: fixed;
    131 }
    132 
    133 .md-content .highlighttable td:first-child {
    134     width: 40px;
    135 }
    136 
    137 .md-content .highlighttable td .linenodiv {
    138     padding-inline-end: 0 !important;
    139 }
    140 
    141 .md-content .highlighttable td .highlight,
    142 .md-content .highlighttable td .linenodiv pre {
    143     margin-bottom: 0;
    144 }
    145 
    146 .post-content code {
    147     padding: 0.2rem 0.3rem;
    148     font-size: 0.78em;
    149     line-height: 1.5;
    150     background: var(--code-bg);
    151     border-radius: 0.2rem;
    152 }
    153 
    154 .md-content pre code {
    155     display: grid;
    156     margin: auto 0;
    157     padding: 10px;
    158     color: rgb(213, 213, 214);
    159     background: var(--code-block-bg) !important;
    160     border-radius: var(--radius);
    161     overflow-x: auto;
    162     word-break: break-all;
    163 }
    164 
    165 .md-content blockquote {
    166     margin: 1rem 0;
    167     padding-inline-start: 1rem;
    168     border-inline-start: 0.3rem solid var(--content);
    169 }
    170 
    171 .md-content hr {
    172     margin: 30px 0;
    173     height: 2px;
    174     background: var(--tertiary);
    175     border: 0;
    176 }
    177 
    178 .md-content iframe {
    179     max-width: 100%;
    180 }
    181 
    182 .md-content img {
    183     border-radius: var(--radius);
    184     margin: 1rem 0;
    185 }
    186 
    187 .md-content img[src*="#center"] {
    188     margin: 1rem auto;
    189 }
    190 
    191 .md-content figure.align-center {
    192     text-align: center;
    193 }
    194 
    195 .md-content figure>figcaption {
    196     color: var(--primary);
    197     font-size: 16px;
    198     font-weight: bold;
    199     margin: 8px 0 16px;
    200 }
    201 
    202 .md-content figure>figcaption>p {
    203     color: var(--secondary);
    204     font-size: 14px;
    205     font-weight: normal;
    206 }
    207 
    208 .md-content h1:hover .anchor,
    209 .md-content h2:hover .anchor,
    210 .md-content h3:hover .anchor,
    211 .md-content h4:hover .anchor,
    212 .md-content h5:hover .anchor,
    213 .md-content h6:hover .anchor {
    214     display: inline-flex;
    215     color: var(--secondary);
    216     margin-inline-start: 0.5em;
    217     font-weight: 500;
    218     user-select: none;
    219 }
    220 
    221 .anchor:hover {
    222     color: var(--content) !important;
    223 }
    224 
    225 .md-content img.in-text {
    226     display: inline;
    227     margin: auto;
    228 }
    229 
    230 mark {
    231     border-radius: 2px;
    232     padding: 0 2px;
    233 }
    234 
    235 audio {
    236     display: block;
    237     width: 100%;
    238     border: 1px solid var(--border);
    239     border-radius: var(--radius);
    240     overflow: hidden;
    241     height: 2.5rem;
    242     margin-bottom: var(--content-gap);
    243 }
    244 
    245 audio::-webkit-media-controls-enclosure {
    246     border-radius: 0;
    247 }
    248 
    249 video {
    250     border: 1px solid var(--code-bg);
    251     border-radius: var(--radius);
    252     max-width: 100%;
    253 }