{"version":3,"file":"blocks/TableOfContents/style-index.css","mappings":";;;AAyBA;EACC;EAEA;AAzBD;AA2BC;EACC;EACA;EACA;EACA;EACA;EACA;EACA;AAzBF;AA4BC;EACC;EACA;EACA;EACA;EACA;EACA;EACA;AA1BF;AA4BE;EACC;EACA;AA1BH;AA8BC;EACC;EACA;AA5BF;AA+BC;EACC;AA7BF;AAgCC;EACC;EACA;EACA;EACA;AA9BF;AAgCE;EACC;AA9BH;AAiCE;EACC;EACA;AA/BH;AAoCE;EACC;EACA;AAlCH;AAsCC;EACC;IACC;EApCD;AACF;;AA2CC;EACC;EAIA;AA3CF;AAgDC;EACC;AA9CF;AAiDC;EACC;AA/CF;AAwDC;EACC;AAtDF;AA2DC;EACC;AAzDF;AA2DE;EACC;AAzDH;AA2DG;EACC;AAzDJ;AA8DC;EACC;EACA;AA5DF;AA8DE;EACC;AA5DH,C","sources":["webpack://brandy-blocks/./src/blocks/TableOfContents/style.scss"],"sourcesContent":["// Table of Contents — shared editor + frontend styles.\n//\n// Nesting is real markup in both runtimes (lists inside list items), so the\n// indentation comes from each list's own padding rather than per-level classes.\n//\n// SPECIFICITY, AND WHY THE LIST RULES LOOK OVER-QUALIFIED\n// -------------------------------------------------------\n// Host themes routinely reset lists. Brandy's own is\n//\n//   ul:not(.wp-block-list, .woocommerce-Tabs-panel--description ul, …),\n//   ol:not(…) { padding: 0; list-style-type: none }\n//\n// `:not()` takes the specificity of its most specific argument, so that lands\n// at (0,1,2) — enough to beat a plain `.brandy-toc__list` (0,1,0) and strip\n// both the marker and the indent. With `list-style-position: outside` a\n// zero-padding list renders its markers outside the box, where they get\n// clipped: the block looked marker-less even once the marker was declared.\n// In the editor a theme reset can gain another class again, since WordPress\n// prefixes `add_editor_style()` sheets with `.editor-styles-wrapper`.\n//\n// So every rule that a list reset can touch — marker, padding, margin — is\n// anchored on both classes the wrapper always carries, giving (0,3,0) or more.\n// That clears the reset on any theme without the block needing to be named in\n// some theme's opt-out list.\n\n.brandy-toc {\n\t--brandy-toc-indent: 1.35em;\n\n\tbox-sizing: border-box;\n\n\t&__header {\n\t\tdisplay: flex;\n\t\talign-items: center;\n\t\tjustify-content: space-between;\n\t\tgap: 0.5em;\n\t\twidth: 100%;\n\t\tmargin: 0 0 0.5em;\n\t\tfont-weight: 600;\n\t}\n\n\t&__toggle {\n\t\tbackground: none;\n\t\tborder: 0;\n\t\tpadding: 0;\n\t\tcolor: inherit;\n\t\tfont: inherit;\n\t\tcursor: pointer;\n\t\ttext-align: left;\n\n\t\t&:focus-visible {\n\t\t\toutline: 2px solid currentColor;\n\t\t\toutline-offset: 2px;\n\t\t}\n\t}\n\n\t&__caret {\n\t\tflex: 0 0 auto;\n\t\ttransition: transform 0.2s ease;\n\t}\n\n\t&.is-collapsed &__caret {\n\t\ttransform: rotate(-90deg);\n\t}\n\n\t&__link {\n\t\tdisplay: inline-block;\n\t\ttext-decoration: none;\n\t\tcolor: inherit;\n\t\ttransition: color 0.15s ease, opacity 0.15s ease;\n\n\t\t&:hover {\n\t\t\ttext-decoration: underline;\n\t\t}\n\n\t\t&:focus-visible {\n\t\t\toutline: 2px solid currentColor;\n\t\t\toutline-offset: 2px;\n\t\t}\n\n\t\t// Scroll-spy. Weight rather than colour alone, so the current section\n\t\t// is still distinguishable without relying on colour perception.\n\t\t&.is-active {\n\t\t\tfont-weight: 700;\n\t\t\ttext-decoration: underline;\n\t\t}\n\t}\n\n\t@media (prefers-reduced-motion: reduce) {\n\t\t&__caret {\n\t\t\ttransition: none;\n\t\t}\n\t}\n}\n\n// Everything a list reset can reach lives here, anchored on both wrapper\n// classes so it out-specifies one. See the specificity note at the top.\n.brandy-toc.wp-block-brandy-table-of-contents {\n\t.brandy-toc__list {\n\t\tmargin: 0;\n\t\t// Restores the indent the reset zeroes. Markers are positioned\n\t\t// `outside`, so without this they render beyond the list box and are\n\t\t// clipped — declaring the marker alone is not enough.\n\t\tpadding-left: var(--brandy-toc-indent);\n\t}\n\n\t// Nested lists sit inside their parent item; the extra top margin keeps\n\t// them from crowding the link above.\n\t.brandy-toc__list .brandy-toc__list {\n\t\tmargin-top: 0.25em;\n\t}\n\n\t.brandy-toc__item {\n\t\tmargin: 0 0 0.25em;\n\t}\n\n\t// Markers are declared for every mode, including numbered: leaving that one\n\t// to the browser default is what let the theme's `list-style-type: none`\n\t// strip the numbering outright.\n\t//\n\t// `outside` is stated for the same reason — a reset flipping it to `inside`\n\t// pulls the marker into the link text and breaks the indent alignment.\n\t&.is-list-numbered .brandy-toc__list {\n\t\tlist-style: decimal outside;\n\t}\n\n\t// Nested levels change marker so the hierarchy stays readable — this is the\n\t// browser's own ul behaviour, which forcing `disc` everywhere had removed.\n\t&.is-list-bulleted .brandy-toc__list {\n\t\tlist-style: disc outside;\n\n\t\t.brandy-toc__list {\n\t\t\tlist-style: circle outside;\n\n\t\t\t.brandy-toc__list {\n\t\t\t\tlist-style: square outside;\n\t\t\t}\n\t\t}\n\t}\n\n\t&.is-list-plain .brandy-toc__list {\n\t\tlist-style: none;\n\t\tpadding-left: 0;\n\n\t\t.brandy-toc__list {\n\t\t\tpadding-left: var(--brandy-toc-indent);\n\t\t}\n\t}\n}\n\n// The editor preview used to fake nesting with per-level padding on a flat\n// list. It now renders the same nested lists as the front end, so the indent\n// comes from the lists themselves and these rules are gone.\n"],"names":[],"sourceRoot":""}